Skip to content

Commit

Permalink
Merge pull request #1 from dcpesses/feature/remove-prettierjs
Browse files Browse the repository at this point in the history
Remove Prettier
  • Loading branch information
dcpesses authored Feb 13, 2024
2 parents 111eb20 + 6e3b148 commit f52a358
Show file tree
Hide file tree
Showing 6 changed files with 178 additions and 5,214 deletions.
87 changes: 81 additions & 6 deletions .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,9 @@ module.exports = {
'plugin:@typescript-eslint/recommended',
'plugin:react/recommended',
'plugin:react-hooks/recommended',
'plugin:prettier/recommended',
'plugin:react/jsx-runtime',
'prettier',
],
plugins: ['react', 'prettier', 'unused-imports', 'simple-import-sort'],
plugins: ['react', 'unused-imports'],
settings: {
react: {
version: 'detect',
Expand All @@ -26,9 +24,86 @@ module.exports = {
},
],
rules: {
'prettier/prettier': 'warn',
'unused-imports/no-unused-imports': 'warn',
'simple-import-sort/imports': 'warn',
'simple-import-sort/exports': 'warn',

'array-bracket-spacing': ['error', 'never'],
'block-spacing': ['error', 'never'],
'brace-style': ['error', '1tbs', {allowSingleLine: true}],
'comma-spacing': ['error', {before: false, after: true}],
curly: ['error'],
'dot-location': ['error', 'property'],
'dot-notation': ['error'],
'eol-last': ['error'],
eqeqeq: ['error'],
indent: ['error', 2, {SwitchCase: 0, VariableDeclarator: 1}],
'jsx-quotes': ['error', 'prefer-double'],
'keyword-spacing': ['error'],
'no-case-declarations': [0],
'no-console': [1, {allow: ['warn', 'error']}],
'no-debugger': [1],
'no-empty': ['error'],
'no-extend-native': ['error'],
'no-extra-semi': ['error'],
'no-multi-spaces': ['error'],
'no-restricted-syntax': ['error', 'WithStatement'],
'no-shadow': [
'error',
{
builtinGlobals: true,
allow: [
'Event',
'History',
'Notification',
'Permissions',
'Promise',
'Request',
'event',
'history',
'location',
'open',
'screen',
'status',
],
},
],
'no-sparse-arrays': ['error'],
'no-trailing-spaces': ['error'],
'no-unexpected-multiline': ['error'],
'no-unneeded-ternary': ['error'],
'no-unreachable': ['error'],
'no-unsafe-finally': ['error'],
'no-unused-vars': ['error'],
quotes: ['error', 'single', 'avoid-escape'],
semi: ['error', 'always'],
'space-before-blocks': ['error', 'always'],
'space-before-function-paren': ['error', 'never'],
'use-isnan': ['error'],
'valid-typeof': ['error'],

'react/jsx-indent': ['error', 2],
'react/jsx-no-duplicate-props': ['error'],
'react/jsx-uses-react': ['error'],
'react/jsx-uses-vars': ['error'],
'react/no-access-state-in-setstate': ['error'],
'react/no-children-prop': ['error'],
'react/no-deprecated': [1],
'react/no-danger-with-children': ['error'],
'react/no-did-mount-set-state': ['error'],
'react/no-did-update-set-state': ['error'],
'react/no-direct-mutation-state': ['error'],
'react/no-render-return-value': ['error'],
'react/no-typos': ['error'],
'react/no-unescaped-entities': ['error'],
'react/no-unknown-property': ['error'],
'react/no-unused-prop-types': [1],
'react/no-unused-state': ['error'],
'react/no-will-update-set-state': ['error'],
'react/prop-types': ['error'],
'react/require-default-props': [1],
'react/require-render-return': ['error'],
'react/self-closing-comp': ['error', {'component': true, 'html': false}],
'react/sort-comp': ['error'],
'react/sort-prop-types': ['error'],
'react/void-dom-elements-no-children': ['error']
},
};
9 changes: 0 additions & 9 deletions .prettierrc.js

This file was deleted.

2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ Based on https://github.com/pchmn/vite-react-ts-ghactions-template/

- VSCode settings & extensions recommendations
- [EditorConfig](https://editorconfig.org/)
- [ESLint](https://eslint.org/) & [Prettier](https://prettier.io/) configured (with [`eslint-plugin-prettier`](https://github.com/prettier/eslint-plugin-prettier))
- [ESLint](https://eslint.org/) configured

### Git Hooks

Expand Down
Loading

0 comments on commit f52a358

Please sign in to comment.