|
3 | 3 | "typeAware": true, |
4 | 4 | "denyWarnings": true |
5 | 5 | }, |
6 | | - "plugins": ["oxc", "import", "typescript"], |
| 6 | + "plugins": ["oxc", "typescript", "unicorn", "import"], |
7 | 7 | "categories": { |
8 | | - "correctness": "error" |
| 8 | + "correctness": "error", |
| 9 | + "suspicious": "error" |
9 | 10 | }, |
10 | 11 | "env": { |
11 | 12 | "node": true, |
|
16 | 17 | "NW": "readonly" |
17 | 18 | }, |
18 | 19 | "rules": { |
| 20 | + "typescript/no-unsafe-type-assertion": "off", |
| 21 | + "eslint/complexity": ["error", 15], |
| 22 | + "eslint/curly": "error", |
| 23 | + "eslint/no-await-in-loop": "off", |
| 24 | + "eslint/no-console": "off", |
| 25 | + "eslint/no-control-regex": "off", |
| 26 | + "eslint/no-empty": [ |
| 27 | + "error", |
| 28 | + { |
| 29 | + "allowEmptyCatch": true |
| 30 | + } |
| 31 | + ], |
| 32 | + "eslint/no-new": "error", |
| 33 | + "eslint/no-proto": "error", |
| 34 | + "eslint/no-shadow": "error", |
| 35 | + "eslint/no-underscore-dangle": "off", |
| 36 | + "eslint/no-unmodified-loop-condition": "off", |
| 37 | + "eslint/no-unused-vars": [ |
| 38 | + "error", |
| 39 | + { |
| 40 | + "args": "all", |
| 41 | + "argsIgnorePattern": "^_", |
| 42 | + "varsIgnorePattern": "^$", |
| 43 | + "caughtErrors": "all", |
| 44 | + "caughtErrorsIgnorePattern": "^_", |
| 45 | + "destructuredArrayIgnorePattern": "^_", |
| 46 | + "ignoreRestSiblings": false |
| 47 | + } |
| 48 | + ], |
| 49 | + "eslint/no-useless-catch": "off", |
| 50 | + "eslint/no-var": "error", |
| 51 | + "eslint/prefer-const": "error", |
| 52 | + "eslint/prefer-regex-literals": [ |
| 53 | + "error", |
| 54 | + { |
| 55 | + "disallowRedundantWrapping": true |
| 56 | + } |
| 57 | + ], |
| 58 | + "eslint/preserve-caught-error": "off", |
| 59 | + "eslint/sort-imports": "off", |
| 60 | + "import/no-cycle": "off", |
| 61 | + "import/no-named-as-default": "off", |
| 62 | + "import/no-named-as-default-member": "off", |
| 63 | + "import/no-self-import": "error", |
| 64 | + "import/no-unassigned-import": "off", |
| 65 | + "typescript/array-type": [ |
| 66 | + "error", |
| 67 | + { |
| 68 | + "default": "array-simple" |
| 69 | + } |
| 70 | + ], |
| 71 | + "typescript/consistent-type-assertions": [ |
| 72 | + "error", |
| 73 | + { |
| 74 | + "assertionStyle": "as" |
| 75 | + } |
| 76 | + ], |
| 77 | + "typescript/consistent-type-imports": "error", |
| 78 | + "typescript/no-duplicate-enum-values": "error", |
| 79 | + "typescript/no-duplicate-type-constituents": [ |
| 80 | + "error", |
| 81 | + { |
| 82 | + "ignoreUnions": true |
| 83 | + } |
| 84 | + ], |
| 85 | + "typescript/no-explicit-any": "error", |
| 86 | + "typescript/no-extra-non-null-assertion": "error", |
| 87 | + "typescript/no-extraneous-class": "off", |
| 88 | + "typescript/no-misused-new": "error", |
| 89 | + "typescript/no-non-null-asserted-optional-chain": "off", |
| 90 | + "typescript/no-redundant-type-constituents": "off", |
| 91 | + "typescript/no-this-alias": [ |
| 92 | + "error", |
| 93 | + { |
| 94 | + "allowDestructuring": true |
| 95 | + } |
| 96 | + ], |
| 97 | + "typescript/no-unnecessary-type-assertion": "off", |
| 98 | + "typescript/no-useless-empty-export": "error", |
| 99 | + "typescript/no-wrapper-object-types": "error", |
| 100 | + "typescript/prefer-as-const": "error", |
| 101 | + "typescript/triple-slash-reference": "error", |
| 102 | + "unicorn/consistent-function-scoping": "off", |
| 103 | + "unicorn/no-array-for-each": "off", |
| 104 | + "unicorn/no-array-reverse": "error", |
| 105 | + "unicorn/no-array-sort": "error", |
| 106 | + "unicorn/no-empty-file": "off", |
| 107 | + "unicorn/no-null": "off", |
| 108 | + "unicorn/no-useless-fallback-in-spread": "off", |
| 109 | + "unicorn/numeric-separators-style": "error", |
| 110 | + "unicorn/prefer-node-protocol": "error", |
| 111 | + "unicorn/prefer-spread": "off", |
19 | 112 | "no-console": "off", |
20 | 113 | "typescript/no-floating-promises": "error", |
21 | 114 | "typescript/no-misused-promises": "error", |
22 | 115 | "typescript/await-thenable": "error" |
23 | 116 | }, |
24 | 117 | "overrides": [ |
| 118 | + { |
| 119 | + "files": ["**/src/dom-selector.mts"], |
| 120 | + "rules": { "typescript/consistent-type-imports": "off" } |
| 121 | + }, |
| 122 | + { |
| 123 | + "files": ["**/*.mts", "**/*.ts"], |
| 124 | + "rules": { |
| 125 | + "eslint/no-unused-vars": "off" |
| 126 | + } |
| 127 | + }, |
25 | 128 | { |
26 | 129 | "files": ["**/src/**/*.mts"], |
27 | 130 | "rules": { |
|
35 | 138 | "default-case": "error", |
36 | 139 | "no-duplicate-case": "error", |
37 | 140 | "radix": "error", |
38 | | - "no-with": "error" |
| 141 | + "no-with": "error", |
| 142 | + "eslint/no-var": "off", |
| 143 | + "eslint/block-scoped-var": "off", |
| 144 | + "unicorn/numeric-separators-style": "off", |
| 145 | + "typescript/no-unnecessary-boolean-literal-compare": "off", |
| 146 | + "typescript/no-unnecessary-type-conversion": "off", |
| 147 | + "typescript/unbound-method": "off", |
| 148 | + "eslint/prefer-const": "off", |
| 149 | + "eslint/complexity": "off", |
| 150 | + "eslint/no-shadow": "off", |
| 151 | + "typescript/no-explicit-any": "off" |
39 | 152 | } |
40 | 153 | } |
41 | 154 | ] |
|
0 commit comments