|
| 1 | +{ |
| 2 | + "env": { |
| 3 | + "browser": true, |
| 4 | + "es2021": true |
| 5 | + }, |
| 6 | + "extends": [ |
| 7 | + "eslint:recommended", |
| 8 | + "plugin:@typescript-eslint/recommended", |
| 9 | + "plugin:import/recommended", |
| 10 | + "plugin:import/typescript", |
| 11 | + "plugin:react/recommended", |
| 12 | + "plugin:prettier/recommended", |
| 13 | + "plugin:react-hooks/recommended", |
| 14 | + "plugin:sonarjs/recommended" |
| 15 | + ], |
| 16 | + "parser": "@typescript-eslint/parser", |
| 17 | + "parserOptions": { |
| 18 | + "ecmaVersion": 12, |
| 19 | + "sourceType": "module", |
| 20 | + "ecmaFeatures": { |
| 21 | + "jsx": true |
| 22 | + } |
| 23 | + }, |
| 24 | + "plugins": [ |
| 25 | + "@typescript-eslint", |
| 26 | + "react", |
| 27 | + "prettier", |
| 28 | + "eslint-plugin-import-helpers", |
| 29 | + "import", |
| 30 | + "react-hooks", |
| 31 | + "sonarjs" |
| 32 | + ], |
| 33 | + "rules": { |
| 34 | + "prettier/prettier": "error", |
| 35 | + "linebreak-style": ["error", "unix"], |
| 36 | + "max-len": [ |
| 37 | + "error", |
| 38 | + { |
| 39 | + "code": 80, |
| 40 | + "ignoreStrings": true, |
| 41 | + "ignoreComments": true, |
| 42 | + "ignoreRegExpLiterals": true, |
| 43 | + "ignorePattern": "^\\s*\\w+\\s*\\(.*\\).+;$" |
| 44 | + } |
| 45 | + ], |
| 46 | + "import-helpers/order-imports": [ |
| 47 | + "error", |
| 48 | + { |
| 49 | + "newlinesBetween": "always", |
| 50 | + "groups": ["/^react/", "module", ["parent", "sibling", "index"]], |
| 51 | + "alphabetize": { "order": "asc", "ignoreCase": true } |
| 52 | + } |
| 53 | + ], |
| 54 | + "no-console": "warn", |
| 55 | + "no-nested-ternary": "off", |
| 56 | + "react/jsx-filename-extension": ["warn", { "extensions": [".tsx"] }], |
| 57 | + "react-hooks/rules-of-hooks": "error", |
| 58 | + "react-hooks/exhaustive-deps": "warn", |
| 59 | + "react/prop-types": "off", |
| 60 | + "import/no-unresolved": "error", |
| 61 | + "import/prefer-default-export": "off" |
| 62 | + }, |
| 63 | + "settings": { |
| 64 | + "import/resolver": {} |
| 65 | + } |
| 66 | +} |
0 commit comments