@origin-1/eslint-config 1.9.1 → 1.11.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/rules.js +18 -17
- package/package.json +5 -5
package/lib/rules.js
CHANGED
|
@@ -53,6 +53,7 @@ exports.RULES = {
|
|
|
53
53
|
'no-control-regex': 'off',
|
|
54
54
|
'no-debugger': ['error'],
|
|
55
55
|
'no-dupe-args': ['error'],
|
|
56
|
+
'no-dupe-class-members': jsts(['error'], 'off'),
|
|
56
57
|
'no-dupe-else-if': ['error'],
|
|
57
58
|
'no-dupe-keys': ['error'],
|
|
58
59
|
'no-duplicate-case': ['error'],
|
|
@@ -78,6 +79,7 @@ exports.RULES = {
|
|
|
78
79
|
'no-sparse-arrays': 'off',
|
|
79
80
|
'no-template-curly-in-string': 'off',
|
|
80
81
|
'no-this-before-super': ['error'],
|
|
82
|
+
'no-unassigned-vars': ['error'],
|
|
81
83
|
'no-undef': jsts(['error'], 'off'),
|
|
82
84
|
'no-unexpected-multiline': 'off',
|
|
83
85
|
'no-unmodified-loop-condition': 'off',
|
|
@@ -87,6 +89,7 @@ exports.RULES = {
|
|
|
87
89
|
'no-unsafe-negation': ['error'],
|
|
88
90
|
'no-unsafe-optional-chaining': ['error'],
|
|
89
91
|
'no-unused-private-class-members': ['error'],
|
|
92
|
+
'no-use-before-define': 'off',
|
|
90
93
|
'no-useless-assignment': ['error'],
|
|
91
94
|
'no-useless-backreference': ['error'],
|
|
92
95
|
'require-atomic-updates': 'off',
|
|
@@ -97,11 +100,13 @@ exports.RULES = {
|
|
|
97
100
|
'block-scoped-var': 'off',
|
|
98
101
|
'camelcase': 'off',
|
|
99
102
|
'capitalized-comments': 'off',
|
|
103
|
+
'class-methods-use-this': 'off',
|
|
100
104
|
'complexity': 'off',
|
|
101
105
|
'consistent-this': 'off',
|
|
102
106
|
'curly': ['error', 'multi-or-nest'],
|
|
103
107
|
'default-case': 'off',
|
|
104
108
|
'default-case-last': 'off',
|
|
109
|
+
'default-param-last': ['error'],
|
|
105
110
|
'eqeqeq': ['error', 'allow-null'],
|
|
106
111
|
'func-name-matching': 'off',
|
|
107
112
|
'func-names': ['error', 'never'],
|
|
@@ -111,15 +116,18 @@ exports.RULES = {
|
|
|
111
116
|
'id-denylist': 'off',
|
|
112
117
|
'id-length': 'off',
|
|
113
118
|
'id-match': 'off',
|
|
119
|
+
'init-declarations': 'off',
|
|
114
120
|
'logical-assignment-operators': beforeJSOrElse(2021, 'off', ['error', 'always', { enforceForIfStatements: true }]),
|
|
115
121
|
'max-classes-per-file': 'off',
|
|
116
122
|
'max-depth': 'off',
|
|
117
123
|
'max-lines': 'off',
|
|
118
124
|
'max-lines-per-function': 'off',
|
|
119
125
|
'max-nested-callbacks': 'off',
|
|
126
|
+
'max-params': 'off',
|
|
120
127
|
'max-statements': 'off',
|
|
121
128
|
'new-cap': ['error', { capIsNew: false }],
|
|
122
129
|
'no-alert': ['error'],
|
|
130
|
+
'no-array-constructor': ['error'],
|
|
123
131
|
'no-bitwise': 'off',
|
|
124
132
|
'no-caller': ['error'],
|
|
125
133
|
'no-case-declarations': ['error'],
|
|
@@ -129,6 +137,7 @@ exports.RULES = {
|
|
|
129
137
|
'no-div-regex': ['error'],
|
|
130
138
|
'no-else-return': ['error'],
|
|
131
139
|
'no-empty': ['error', { allowEmptyCatch: true }],
|
|
140
|
+
'no-empty-function': 'off',
|
|
132
141
|
'no-empty-static-block': ['error'],
|
|
133
142
|
'no-eq-null': 'off',
|
|
134
143
|
'no-eval': 'off',
|
|
@@ -140,11 +149,14 @@ exports.RULES = {
|
|
|
140
149
|
'no-implicit-coercion': 'off',
|
|
141
150
|
'no-implicit-globals': 'off',
|
|
142
151
|
'no-inline-comments': 'off',
|
|
152
|
+
'no-invalid-this': 'off',
|
|
143
153
|
'no-iterator': ['error'],
|
|
144
154
|
'no-label-var': ['error'],
|
|
145
155
|
'no-labels': ['error', { allowLoop: true, allowSwitch: true }],
|
|
146
156
|
'no-lone-blocks': beforeJSOrElse(2015, ['error'], 'off'),
|
|
147
157
|
'no-lonely-if': 'off',
|
|
158
|
+
'no-loop-func': ['error'],
|
|
159
|
+
'no-magic-numbers': 'off',
|
|
148
160
|
'no-multi-assign': 'off',
|
|
149
161
|
'no-multi-str': ['error'],
|
|
150
162
|
'no-negated-condition': 'off',
|
|
@@ -167,18 +179,21 @@ exports.RULES = {
|
|
|
167
179
|
'no-return-assign': ['error', 'always'],
|
|
168
180
|
'no-script-url': ['error'],
|
|
169
181
|
'no-sequences': ['error'],
|
|
170
|
-
'no-shadow
|
|
182
|
+
'no-shadow': 'off',
|
|
183
|
+
'no-shadow-restricted-names': ['error', { reportGlobalThis: true }],
|
|
171
184
|
'no-ternary': 'off',
|
|
172
185
|
'no-throw-literal': jsts(['error'], 'off'),
|
|
173
186
|
'no-undef-init': ['error'],
|
|
174
187
|
'no-undefined': 'off',
|
|
175
188
|
'no-underscore-dangle': 'off',
|
|
176
189
|
'no-unneeded-ternary': ['error'],
|
|
190
|
+
'no-unused-expressions': ['error'],
|
|
177
191
|
'no-unused-labels': ['error'],
|
|
178
192
|
'no-useless-call': ['error'],
|
|
179
193
|
'no-useless-catch': ['error'],
|
|
180
|
-
'no-useless-computed-key': ['error'
|
|
194
|
+
'no-useless-computed-key': ['error'],
|
|
181
195
|
'no-useless-concat': ['error'],
|
|
196
|
+
'no-useless-constructor': ['error'],
|
|
182
197
|
'no-useless-escape': ['error'],
|
|
183
198
|
'no-useless-rename': ['error'],
|
|
184
199
|
'no-useless-return': ['error'],
|
|
@@ -213,26 +228,12 @@ exports.RULES = {
|
|
|
213
228
|
'unicode-bom': ['error'],
|
|
214
229
|
},
|
|
215
230
|
[exports.HYBRID]: {
|
|
216
|
-
'no-dupe-class-members': jsts(['error'], 'off'),
|
|
217
231
|
'no-unused-vars': beforeJSOrElse(2018, ['error', { caughtErrors: 'none', vars: 'local' }], 2019, ['error', { caughtErrors: 'none', ignoreRestSiblings: true, vars: 'local' }], ['error', { ignoreRestSiblings: true, vars: 'local' }]),
|
|
218
|
-
'no-use-before-define': 'off',
|
|
219
|
-
'class-methods-use-this': 'off',
|
|
220
232
|
'consistent-return': 'off',
|
|
221
|
-
'default-param-last': 'off',
|
|
222
233
|
'dot-notation': ['error'],
|
|
223
|
-
'init-declarations': 'off',
|
|
224
|
-
'max-params': 'off',
|
|
225
|
-
'no-array-constructor': ['error'],
|
|
226
|
-
'no-empty-function': 'off',
|
|
227
234
|
'no-implied-eval': 'off',
|
|
228
|
-
'no-invalid-this': 'off',
|
|
229
|
-
'no-loop-func': ['error'],
|
|
230
|
-
'no-magic-numbers': 'off',
|
|
231
235
|
'no-redeclare': jsts(['error', { builtinGlobals: true }], 'off'),
|
|
232
236
|
'no-restricted-imports': 'off',
|
|
233
|
-
'no-shadow': 'off',
|
|
234
|
-
'no-unused-expressions': ['error'],
|
|
235
|
-
'no-useless-constructor': ['error'],
|
|
236
237
|
'prefer-destructuring': beforeJSOrElse(2015, 'off', ['error']),
|
|
237
238
|
'prefer-promise-reject-errors': 'off',
|
|
238
239
|
'require-await': ['error'],
|
|
@@ -315,6 +316,7 @@ exports.RULES = {
|
|
|
315
316
|
'no-unnecessary-type-arguments': ['error'],
|
|
316
317
|
'no-unnecessary-type-assertion': ['error'],
|
|
317
318
|
'no-unnecessary-type-constraint': ['error'],
|
|
319
|
+
'no-unnecessary-type-conversion': ['error'],
|
|
318
320
|
'no-unsafe-enum-comparison': ['error'],
|
|
319
321
|
'no-useless-empty-export': ['error'],
|
|
320
322
|
'non-nullable-type-assertion-style': ['error'],
|
|
@@ -337,7 +339,6 @@ exports.RULES = {
|
|
|
337
339
|
'strict-boolean-expressions': 'off',
|
|
338
340
|
'switch-exhaustiveness-check': ['error', { considerDefaultExhaustiveForUnions: true }],
|
|
339
341
|
'triple-slash-reference': ['error', { lib: 'never' }],
|
|
340
|
-
'typedef': ['error'],
|
|
341
342
|
'unified-signatures': ['error', { ignoreDifferentlyNamedParameters: true }],
|
|
342
343
|
'use-unknown-in-catch-callback-variable': ['error'],
|
|
343
344
|
},
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@origin-1/eslint-config",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.11.0",
|
|
4
4
|
"description": "ESLint configuration generator with Origin₁ presets",
|
|
5
5
|
"homepage": "https://github.com/origin-1/eslint-config#readme",
|
|
6
6
|
"license": "ISC",
|
|
@@ -16,10 +16,10 @@
|
|
|
16
16
|
"peerDependencies": {
|
|
17
17
|
"@eslint-community/eslint-plugin-eslint-comments": ">=4.1",
|
|
18
18
|
"@origin-1/eslint-plugin": ">=0.16",
|
|
19
|
-
"@stylistic/eslint-plugin": "^
|
|
20
|
-
"@typescript-eslint/eslint-plugin": "^8.
|
|
21
|
-
"@typescript-eslint/parser": "^8.
|
|
22
|
-
"eslint": "^9.
|
|
19
|
+
"@stylistic/eslint-plugin": "^4.0",
|
|
20
|
+
"@typescript-eslint/eslint-plugin": "^8.32",
|
|
21
|
+
"@typescript-eslint/parser": "^8.32",
|
|
22
|
+
"eslint": "^9.28",
|
|
23
23
|
"eslint-plugin-n": "17"
|
|
24
24
|
},
|
|
25
25
|
"engines": {
|