|
| 1 | +{ |
| 2 | + "root": true, |
| 3 | + "parser": "@typescript-eslint/parser", |
| 4 | + "plugins": ["@typescript-eslint", "no-only-tests", "eslint-comments"], |
| 5 | + "ignorePatterns": ["node_modules", "dist"], |
| 6 | + "parserOptions": { |
| 7 | + "project": ["./tsconfig.json", "./tsconfig.node.json", "./test/tsconfig.json"], |
| 8 | + "tsconfigRootDir": ".", |
| 9 | + "sourceType": "module" |
| 10 | + }, |
| 11 | + "rules": { |
| 12 | + /* |
| 13 | + forgot to remove/implement |
| 14 | + */ |
| 15 | + "no-console": "warn", |
| 16 | + "no-debugger": "warn", |
| 17 | + "prefer-const": "warn", |
| 18 | + "require-await": "warn", |
| 19 | + "@typescript-eslint/no-unused-vars": [ |
| 20 | + "warn", |
| 21 | + { |
| 22 | + "argsIgnorePattern": "^_", |
| 23 | + "varsIgnorePattern": "^_", |
| 24 | + "caughtErrorsIgnorePattern": "^_" |
| 25 | + } |
| 26 | + ], |
| 27 | + "@typescript-eslint/no-unnecessary-boolean-literal-compare": "warn", |
| 28 | + "@typescript-eslint/no-unnecessary-condition": "warn", |
| 29 | + "@typescript-eslint/no-unnecessary-type-arguments": "warn", |
| 30 | + "@typescript-eslint/no-unnecessary-type-assertion": "warn", |
| 31 | + "@typescript-eslint/no-unnecessary-type-constraint": "warn", |
| 32 | + "@typescript-eslint/no-useless-empty-export": "warn", |
| 33 | + "@typescript-eslint/no-empty-function": "warn", |
| 34 | + "no-empty": "warn", |
| 35 | + "@typescript-eslint/no-unused-expressions": [ |
| 36 | + "warn", |
| 37 | + {"allowShortCircuit": true, "allowTernary": true} |
| 38 | + ], |
| 39 | + "eslint-comments/no-unused-disable": "warn", |
| 40 | + /* |
| 41 | + code style | readability |
| 42 | + */ |
| 43 | + "@typescript-eslint/explicit-function-return-type": [ |
| 44 | + "warn", |
| 45 | + { |
| 46 | + "allowExpressions": true, |
| 47 | + "allowTypedFunctionExpressions": true, |
| 48 | + "allowHigherOrderFunctions": true, |
| 49 | + "allowDirectConstAssertionInArrowFunctions": true, |
| 50 | + "allowConciseArrowFunctionExpressionsStartingWithVoid": true, |
| 51 | + "allowIIFEs": true |
| 52 | + } |
| 53 | + ], |
| 54 | + /* |
| 55 | + prevent unexpected behavior |
| 56 | + */ |
| 57 | + "@typescript-eslint/ban-types": "warn", |
| 58 | + "@typescript-eslint/switch-exhaustiveness-check": "warn", |
| 59 | + "no-fallthrough": ["warn", {"allowEmptyCase": true}], |
| 60 | + /* |
| 61 | + tests |
| 62 | + */ |
| 63 | + "no-only-tests/no-only-tests": "warn" |
| 64 | + } |
| 65 | +} |
0 commit comments