eslint-config-setup 0.3.3 → 0.5.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.
@@ -1,13 +1,13 @@
1
1
  {
2
2
  "$schema": "./node_modules/oxlint/configuration_schema.json",
3
3
  "plugins": [
4
- "typescript",
5
4
  "import",
6
5
  "unicorn",
7
6
  "jsdoc",
8
7
  "node",
9
8
  "react",
10
- "jsx-a11y"
9
+ "jsx-a11y",
10
+ "react-perf"
11
11
  ],
12
12
  "categories": {
13
13
  "correctness": "off"
@@ -20,6 +20,7 @@
20
20
  "rules": {
21
21
  "constructor-super": "error",
22
22
  "for-direction": "error",
23
+ "getter-return": "error",
23
24
  "no-async-promise-executor": "error",
24
25
  "no-case-declarations": "error",
25
26
  "no-class-assign": "error",
@@ -59,30 +60,31 @@
59
60
  "no-sparse-arrays": "error",
60
61
  "no-this-before-super": "error",
61
62
  "no-unassigned-vars": "error",
63
+ "no-unreachable": "error",
62
64
  "no-unsafe-finally": "error",
63
65
  "no-unsafe-negation": "error",
64
66
  "no-unsafe-optional-chaining": "error",
65
67
  "no-unused-labels": "error",
66
68
  "no-unused-private-class-members": "error",
67
- "no-unused-vars": [
68
- "error",
69
- {
70
- "args": "all",
71
- "argsIgnorePattern": "^_",
72
- "caughtErrors": "all",
73
- "caughtErrorsIgnorePattern": "^_",
74
- "destructuredArrayIgnorePattern": "^_",
75
- "varsIgnorePattern": "^_",
76
- "ignoreRestSiblings": true
77
- }
78
- ],
69
+ "no-unused-vars": "error",
79
70
  "no-useless-catch": "error",
80
71
  "no-useless-escape": "error",
81
72
  "no-with": "error",
82
73
  "preserve-caught-error": "error",
83
74
  "require-yield": "error",
84
- "use-isnan": "error",
85
- "valid-typeof": "error",
75
+ "use-isnan": [
76
+ "error",
77
+ {
78
+ "enforceForIndexOf": true,
79
+ "enforceForSwitchCase": true
80
+ }
81
+ ],
82
+ "valid-typeof": [
83
+ "error",
84
+ {
85
+ "requireStringLiterals": true
86
+ }
87
+ ],
86
88
  "accessor-pairs": [
87
89
  "error",
88
90
  {
@@ -105,7 +107,12 @@
105
107
  "getBeforeSet"
106
108
  ],
107
109
  "no-useless-rename": "error",
108
- "no-useless-computed-key": "error",
110
+ "no-useless-computed-key": [
111
+ "error",
112
+ {
113
+ "enforceForClassMembers": true
114
+ }
115
+ ],
109
116
  "no-eval": "error",
110
117
  "no-alert": "error",
111
118
  "no-caller": "error",
@@ -116,6 +123,7 @@
116
123
  "no-proto": "error",
117
124
  "no-iterator": "error",
118
125
  "no-script-url": "error",
126
+ "no-implicit-globals": "error",
119
127
  "eqeqeq": [
120
128
  "error",
121
129
  "smart"
@@ -124,7 +132,12 @@
124
132
  "default-case-last": "error",
125
133
  "radix": "error",
126
134
  "yoda": "error",
127
- "no-sequences": "error",
135
+ "no-sequences": [
136
+ "error",
137
+ {
138
+ "allowInParentheses": false
139
+ }
140
+ ],
128
141
  "no-new": "error",
129
142
  "no-labels": "error",
130
143
  "no-extra-bind": "error",
@@ -132,7 +145,53 @@
132
145
  "no-useless-call": "error",
133
146
  "no-useless-concat": "error",
134
147
  "no-useless-return": "error",
148
+ "no-return-assign": [
149
+ "error",
150
+ "always"
151
+ ],
135
152
  "no-multi-str": "error",
153
+ "prefer-regex-literals": [
154
+ "error",
155
+ {
156
+ "disallowRedundantWrapping": true
157
+ }
158
+ ],
159
+ "complexity": [
160
+ "error",
161
+ 10
162
+ ],
163
+ "max-depth": [
164
+ "error",
165
+ 3
166
+ ],
167
+ "max-nested-callbacks": [
168
+ "error",
169
+ 2
170
+ ],
171
+ "max-params": [
172
+ "error",
173
+ 3
174
+ ],
175
+ "max-statements": [
176
+ "error",
177
+ 15
178
+ ],
179
+ "max-lines-per-function": [
180
+ "error",
181
+ {
182
+ "max": 100,
183
+ "skipBlankLines": true,
184
+ "skipComments": true
185
+ }
186
+ ],
187
+ "max-lines": [
188
+ "error",
189
+ {
190
+ "max": 300,
191
+ "skipBlankLines": true,
192
+ "skipComments": true
193
+ }
194
+ ],
136
195
  "no-var": "error",
137
196
  "prefer-const": [
138
197
  "error",
@@ -144,96 +203,55 @@
144
203
  "prefer-object-spread": "error",
145
204
  "prefer-rest-params": "error",
146
205
  "prefer-spread": "error",
147
- "prefer-template": "error",
148
206
  "symbol-description": "error",
149
- "@typescript-eslint/ban-ts-comment": [
150
- "error",
151
- {
152
- "minimumDescriptionLength": 10
153
- }
154
- ],
155
- "no-array-constructor": "error",
156
- "@typescript-eslint/no-duplicate-enum-values": "error",
157
- "@typescript-eslint/no-dynamic-delete": "error",
158
- "@typescript-eslint/no-empty-object-type": "error",
159
- "@typescript-eslint/no-explicit-any": [
207
+ "prefer-numeric-literals": "error",
208
+ "object-shorthand": [
160
209
  "error",
210
+ "always",
161
211
  {
162
- "fixToUnknown": true
212
+ "avoidExplicitReturnArrows": true,
213
+ "avoidQuotes": true
163
214
  }
164
215
  ],
165
- "@typescript-eslint/no-extra-non-null-assertion": "error",
166
- "@typescript-eslint/no-extraneous-class": "error",
167
- "@typescript-eslint/no-invalid-void-type": "error",
168
- "@typescript-eslint/no-misused-new": "error",
169
- "@typescript-eslint/no-namespace": "error",
170
- "@typescript-eslint/no-non-null-asserted-nullish-coalescing": "error",
171
- "@typescript-eslint/no-non-null-asserted-optional-chain": "error",
172
- "@typescript-eslint/no-non-null-assertion": "error",
173
- "@typescript-eslint/no-require-imports": "error",
174
- "@typescript-eslint/no-this-alias": "error",
175
- "@typescript-eslint/no-unnecessary-type-constraint": "error",
176
- "@typescript-eslint/no-unsafe-declaration-merging": "error",
177
- "@typescript-eslint/no-unsafe-function-type": "error",
178
- "no-unused-expressions": "error",
179
- "no-useless-constructor": "error",
180
- "@typescript-eslint/no-wrapper-object-types": "error",
181
- "@typescript-eslint/prefer-as-const": "error",
182
- "@typescript-eslint/prefer-literal-enum-member": "error",
183
- "@typescript-eslint/prefer-namespace-keyword": "error",
184
- "@typescript-eslint/triple-slash-reference": "error",
185
- "@typescript-eslint/unified-signatures": "error",
186
- "@typescript-eslint/adjacent-overload-signatures": "error",
187
- "@typescript-eslint/array-type": [
216
+ "prefer-template": "error",
217
+ "no-else-return": [
188
218
  "error",
189
219
  {
190
- "default": "array-simple"
220
+ "allowElseIf": false
191
221
  }
192
222
  ],
193
- "@typescript-eslint/ban-tslint-comment": "error",
194
- "@typescript-eslint/class-literal-property-style": "error",
195
- "@typescript-eslint/consistent-generic-constructors": "error",
196
- "@typescript-eslint/consistent-indexed-object-style": "error",
197
- "@typescript-eslint/consistent-type-assertions": "error",
198
- "@typescript-eslint/consistent-type-definitions": [
199
- "error",
200
- "type"
201
- ],
202
- "@typescript-eslint/no-confusing-non-null-assertion": "error",
203
- "no-empty-function": "error",
204
- "@typescript-eslint/no-inferrable-types": "error",
205
- "@typescript-eslint/prefer-for-of": "error",
206
- "@typescript-eslint/prefer-function-type": "error",
207
- "@typescript-eslint/consistent-type-imports": [
223
+ "no-nested-ternary": "error",
224
+ "no-unneeded-ternary": "error",
225
+ "no-negated-condition": "error",
226
+ "no-lonely-if": "error",
227
+ "no-param-reassign": [
208
228
  "error",
209
229
  {
210
- "fixStyle": "inline-type-imports"
230
+ "props": true
211
231
  }
212
232
  ],
213
- "@typescript-eslint/no-import-type-side-effects": "error",
214
- "@typescript-eslint/no-useless-empty-export": "error",
215
- "@typescript-eslint/no-unnecessary-parameter-property-assignment": "error",
216
- "no-shadow": [
233
+ "no-multi-assign": "error",
234
+ "no-implicit-coercion": "error",
235
+ "arrow-body-style": "error",
236
+ "prefer-arrow-callback": [
217
237
  "error",
218
238
  {
219
- "hoist": "all",
220
- "allow": [
221
- "resolve",
222
- "reject",
223
- "done",
224
- "next",
225
- "error"
226
- ],
227
- "ignoreTypeValueShadow": true,
228
- "ignoreFunctionTypeParameterNameValueShadow": true
239
+ "allowNamedFunctions": true
229
240
  }
230
241
  ],
231
- "import/no-duplicates": [
242
+ "logical-assignment-operators": [
232
243
  "error",
244
+ "always",
233
245
  {
234
- "prefer-inline": true
246
+ "enforceForIfStatements": true
235
247
  }
236
248
  ],
249
+ "prefer-exponentiation-operator": "error",
250
+ "prefer-named-capture-group": "error",
251
+ "require-unicode-regexp": "error",
252
+ "no-warning-comments": "warn",
253
+ "no-await-in-loop": "error",
254
+ "import/no-duplicates": "error",
237
255
  "import/no-self-import": "error",
238
256
  "import/no-cycle": [
239
257
  "error",
@@ -243,10 +261,28 @@
243
261
  ],
244
262
  "import/no-mutable-exports": "error",
245
263
  "import/first": "error",
264
+ "import/newline-after-import": "error",
246
265
  "import/no-named-as-default": "error",
247
266
  "import/no-named-as-default-member": "error",
248
267
  "import/no-empty-named-blocks": "error",
249
268
  "import/no-absolute-path": "error",
269
+ "import/no-unassigned-import": [
270
+ "error",
271
+ {
272
+ "allow": [
273
+ "@babel/polyfill",
274
+ "**/register",
275
+ "**/register.*",
276
+ "**/register/**",
277
+ "**/register/**.*",
278
+ "**/*.css",
279
+ "**/*.scss",
280
+ "**/*.sass",
281
+ "**/*.less"
282
+ ]
283
+ }
284
+ ],
285
+ "import/no-named-default": "error",
250
286
  "unicorn/no-abusive-eslint-disable": "error",
251
287
  "unicorn/no-instanceof-builtins": "error",
252
288
  "unicorn/no-invalid-remove-event-listener": "error",
@@ -256,7 +292,12 @@
256
292
  "unicorn/no-useless-length-check": "error",
257
293
  "unicorn/no-useless-spread": "error",
258
294
  "unicorn/no-useless-promise-resolve-reject": "error",
259
- "unicorn/no-useless-undefined": "error",
295
+ "unicorn/no-useless-undefined": [
296
+ "warn",
297
+ {
298
+ "checkArguments": false
299
+ }
300
+ ],
260
301
  "unicorn/no-await-in-promise-methods": "error",
261
302
  "unicorn/no-negation-in-equality-check": "error",
262
303
  "unicorn/no-thenable": "error",
@@ -274,6 +315,21 @@
274
315
  "unicorn/consistent-empty-array-spread": "error",
275
316
  "unicorn/consistent-date-clone": "error",
276
317
  "unicorn/consistent-existence-index-check": "error",
318
+ "unicorn/consistent-function-scoping": "error",
319
+ "unicorn/filename-case": [
320
+ "error",
321
+ {
322
+ "cases": {
323
+ "camelCase": true,
324
+ "pascalCase": true,
325
+ "kebabCase": true
326
+ },
327
+ "ignore": [
328
+ "__tests__"
329
+ ]
330
+ }
331
+ ],
332
+ "unicorn/no-array-reduce": "error",
277
333
  "unicorn/prefer-array-flat-map": "error",
278
334
  "unicorn/prefer-array-find": "error",
279
335
  "unicorn/prefer-array-flat": "error",
@@ -282,6 +338,7 @@
282
338
  "unicorn/prefer-at": "error",
283
339
  "unicorn/prefer-includes": "error",
284
340
  "unicorn/prefer-modern-dom-apis": "error",
341
+ "unicorn/prefer-dom-node-dataset": "error",
285
342
  "unicorn/prefer-modern-math-apis": "error",
286
343
  "unicorn/prefer-negative-index": "error",
287
344
  "unicorn/prefer-number-properties": "error",
@@ -306,6 +363,12 @@
306
363
  "unicorn/no-unreadable-array-destructuring": "error",
307
364
  "unicorn/no-zero-fractions": "error",
308
365
  "unicorn/numeric-separators-style": "error",
366
+ "unicorn/prefer-export-from": [
367
+ "error",
368
+ {
369
+ "checkUsedVariables": false
370
+ }
371
+ ],
309
372
  "unicorn/prefer-native-coercion-functions": "error",
310
373
  "unicorn/prefer-regexp-test": "error",
311
374
  "unicorn/prefer-spread": "error",
@@ -315,6 +378,19 @@
315
378
  "unicorn/prefer-optional-catch-binding": "error",
316
379
  "unicorn/prefer-date-now": "error",
317
380
  "unicorn/text-encoding-identifier-case": "error",
381
+ "unicorn/prefer-import-meta-properties": "error",
382
+ "unicorn/prefer-ternary": [
383
+ "error",
384
+ "only-single-line"
385
+ ],
386
+ "unicorn/no-useless-switch-case": "error",
387
+ "unicorn/custom-error-definition": "error",
388
+ "unicorn/prefer-default-parameters": "error",
389
+ "unicorn/prefer-logical-operator-over-ternary": "error",
390
+ "unicorn/prefer-math-min-max": "error",
391
+ "unicorn/prefer-set-size": "error",
392
+ "unicorn/explicit-length-check": "error",
393
+ "unicorn/switch-case-braces": "error",
318
394
  "jsdoc/check-access": "error",
319
395
  "jsdoc/check-property-names": "error",
320
396
  "jsdoc/check-tag-names": "error",
@@ -329,14 +405,38 @@
329
405
  "jsdoc/require-property-name": "error",
330
406
  "jsdoc/require-returns": "error",
331
407
  "jsdoc/require-returns-description": "warn",
408
+ "jsdoc/require-throws-type": "error",
409
+ "jsdoc/require-yields-type": "error",
332
410
  "node/no-exports-assign": "error",
333
411
  "node/no-path-concat": "error",
334
- "react/no-children-prop": "error",
412
+ "node/handle-callback-err": "error",
413
+ "react/no-array-index-key": "error",
414
+ "react/no-clone-element": "warn",
335
415
  "react/no-direct-mutation-state": "error",
416
+ "react/forward-ref-uses-ref": "error",
417
+ "react/jsx-key": "error",
418
+ "react/no-unstable-nested-components": "error",
419
+ "react/no-did-mount-set-state": "warn",
420
+ "react/no-did-update-set-state": "warn",
421
+ "react/no-will-update-set-state": "warn",
422
+ "react/hook-use-state": "warn",
423
+ "react/no-children-prop": "error",
336
424
  "react/jsx-no-comment-textnodes": "error",
337
- "react/no-array-index-key": "error",
338
- "react-hooks/rules-of-hooks": "error",
339
- "react-hooks/exhaustive-deps": "error",
425
+ "react/no-namespace": "error",
426
+ "react/no-danger": "warn",
427
+ "react/no-danger-with-children": "error",
428
+ "react/no-find-dom-node": "error",
429
+ "react/no-render-return-value": "error",
430
+ "react/jsx-no-script-url": "warn",
431
+ "react/void-dom-elements-no-children": "error",
432
+ "react/jsx-no-constructed-context-values": "error",
433
+ "react/no-object-type-as-default-prop": "error",
434
+ "react/jsx-no-useless-fragment": "error",
435
+ "react/button-has-type": "error",
436
+ "react/iframe-missing-sandbox": "error",
437
+ "react/jsx-no-target-blank": "error",
438
+ "react/no-unknown-property": "error",
439
+ "react/style-prop-object": "error",
340
440
  "jsx-a11y/alt-text": "error",
341
441
  "jsx-a11y/anchor-has-content": "error",
342
442
  "jsx-a11y/anchor-is-valid": "error",
@@ -352,12 +452,6 @@
352
452
  "jsx-a11y/label-has-associated-control": "error",
353
453
  "jsx-a11y/mouse-events-have-key-events": "error",
354
454
  "jsx-a11y/no-access-key": "error",
355
- "jsx-a11y/no-autofocus": [
356
- "error",
357
- {
358
- "ignoreNonDOM": true
359
- }
360
- ],
361
455
  "jsx-a11y/no-distracting-elements": "error",
362
456
  "jsx-a11y/no-redundant-roles": "error",
363
457
  "jsx-a11y/role-has-required-aria-props": "error",
@@ -366,121 +460,21 @@
366
460
  "jsx-a11y/tabindex-no-positive": "error",
367
461
  "jsx-a11y/lang": "error",
368
462
  "jsx-a11y/autocomplete-valid": "error",
369
- "no-else-return": [
370
- "error",
371
- {
372
- "allowElseIf": false
373
- }
374
- ],
375
- "no-nested-ternary": "error",
376
- "no-unneeded-ternary": "error",
377
- "no-negated-condition": "error",
378
- "no-lonely-if": "error",
379
- "no-param-reassign": [
380
- "error",
381
- {
382
- "props": true
383
- }
384
- ],
385
- "no-multi-assign": "error",
386
- "no-implicit-coercion": "error",
387
- "arrow-body-style": "error",
388
- "no-return-assign": [
389
- "error",
390
- "always"
391
- ],
392
- "prefer-exponentiation-operator": "error",
393
- "no-warning-comments": "warn",
394
- "no-await-in-loop": "error",
395
- "@typescript-eslint/explicit-function-return-type": [
396
- "error",
397
- {
398
- "allowExpressions": true,
399
- "allowTypedFunctionExpressions": true,
400
- "allowHigherOrderFunctions": true,
401
- "allowIIFEs": true
402
- }
403
- ],
404
- "@typescript-eslint/prefer-enum-initializers": "error",
405
- "unicorn/consistent-function-scoping": "error",
406
- "unicorn/no-array-for-each": "error",
407
- "unicorn/no-array-reduce": "error",
408
- "unicorn/prefer-ternary": [
409
- "error",
410
- "only-single-line"
411
- ],
412
- "unicorn/filename-case": [
463
+ "jsx-a11y/no-autofocus": [
413
464
  "error",
414
465
  {
415
- "cases": {
416
- "camelCase": true,
417
- "pascalCase": true
418
- }
466
+ "ignoreNonDOM": true
419
467
  }
420
468
  ],
421
- "unicorn/no-useless-switch-case": "error",
422
- "unicorn/prefer-default-parameters": "error",
423
- "unicorn/prefer-logical-operator-over-ternary": "error",
424
- "unicorn/prefer-math-min-max": "error",
425
- "unicorn/prefer-set-size": "error",
426
- "unicorn/explicit-length-check": "error",
427
- "unicorn/switch-case-braces": "error",
469
+ "react-perf/jsx-no-jsx-as-prop": "error",
470
+ "react-perf/jsx-no-new-array-as-prop": "error",
471
+ "react-perf/jsx-no-new-function-as-prop": "error",
472
+ "react-perf/jsx-no-new-object-as-prop": "error",
428
473
  "jsx-a11y/no-static-element-interactions": "error",
429
- "complexity": [
430
- "error",
431
- 10
432
- ],
433
- "max-depth": [
434
- "error",
435
- 3
436
- ],
437
- "max-nested-callbacks": [
438
- "error",
439
- 2
440
- ],
441
- "max-params": [
442
- "error",
443
- 3
444
- ],
445
- "max-statements": [
446
- "error",
447
- 15
448
- ],
449
- "max-lines-per-function": [
450
- "error",
451
- {
452
- "max": 50,
453
- "skipBlankLines": true,
454
- "skipComments": true
455
- }
456
- ],
457
- "max-lines": [
458
- "error",
459
- {
460
- "max": 300,
461
- "skipBlankLines": true,
462
- "skipComments": true
463
- }
464
- ],
465
- "no-magic-numbers": [
466
- "error",
467
- {
468
- "ignore": [
469
- -1,
470
- 0,
471
- 1,
472
- 2
473
- ],
474
- "ignoreArrayIndexes": true,
475
- "ignoreDefaultValues": true,
476
- "enforceConst": true,
477
- "ignoreClassFieldInitialValues": true,
478
- "ignoreEnums": true,
479
- "ignoreNumericLiteralTypes": true,
480
- "ignoreReadonlyClassProperties": true,
481
- "ignoreTypeIndexes": true
482
- }
483
- ],
474
+ "jsx-a11y/no-noninteractive-element-interactions": "error",
475
+ "jsx-a11y/interactive-supports-focus": "error",
476
+ "react/rules-of-hooks": "error",
477
+ "react/exhaustive-deps": "warn",
484
478
  "react/only-export-components": [
485
479
  "warn",
486
480
  {
@@ -498,6 +492,7 @@
498
492
  ],
499
493
  "rules": {
500
494
  "constructor-super": "off",
495
+ "getter-return": "off",
501
496
  "no-class-assign": "off",
502
497
  "no-const-assign": "off",
503
498
  "no-dupe-class-members": "off",
@@ -509,9 +504,146 @@
509
504
  "no-redeclare": "off",
510
505
  "no-setter-return": "off",
511
506
  "no-this-before-super": "off",
507
+ "no-unreachable": "off",
512
508
  "no-unsafe-negation": "off",
513
- "no-with": "off"
514
- }
509
+ "no-with": "off",
510
+ "prefer-const": [
511
+ "error",
512
+ {
513
+ "destructuring": "all"
514
+ }
515
+ ],
516
+ "no-array-constructor": "error",
517
+ "no-implied-eval": "off",
518
+ "no-unused-expressions": "error",
519
+ "no-unused-vars": [
520
+ "error",
521
+ {
522
+ "args": "all",
523
+ "argsIgnorePattern": "^_",
524
+ "caughtErrors": "all",
525
+ "caughtErrorsIgnorePattern": "^_",
526
+ "destructuredArrayIgnorePattern": "^_",
527
+ "varsIgnorePattern": "^_",
528
+ "ignoreRestSiblings": true
529
+ }
530
+ ],
531
+ "no-useless-constructor": "error",
532
+ "no-throw-literal": "off",
533
+ "prefer-promise-reject-errors": "off",
534
+ "require-await": "off",
535
+ "no-empty-function": "error",
536
+ "no-shadow": [
537
+ "error",
538
+ {
539
+ "hoist": "all",
540
+ "allow": [
541
+ "resolve",
542
+ "reject",
543
+ "done",
544
+ "next",
545
+ "error"
546
+ ],
547
+ "ignoreTypeValueShadow": true,
548
+ "ignoreFunctionTypeParameterNameValueShadow": true
549
+ }
550
+ ],
551
+ "no-magic-numbers": [
552
+ "error",
553
+ {
554
+ "ignore": [
555
+ -1,
556
+ 0,
557
+ 1,
558
+ 2
559
+ ],
560
+ "ignoreArrayIndexes": true,
561
+ "ignoreDefaultValues": true,
562
+ "enforceConst": true,
563
+ "ignoreClassFieldInitialValues": true,
564
+ "ignoreEnums": true,
565
+ "ignoreNumericLiteralTypes": true,
566
+ "ignoreReadonlyClassProperties": true,
567
+ "ignoreTypeIndexes": true
568
+ }
569
+ ],
570
+ "typescript/ban-ts-comment": [
571
+ "error",
572
+ {
573
+ "ts-expect-error": "allow-with-description"
574
+ }
575
+ ],
576
+ "typescript/no-duplicate-enum-values": "error",
577
+ "typescript/no-dynamic-delete": "error",
578
+ "typescript/no-empty-object-type": "error",
579
+ "typescript/no-explicit-any": "error",
580
+ "typescript/no-extra-non-null-assertion": "error",
581
+ "typescript/no-extraneous-class": "error",
582
+ "typescript/no-invalid-void-type": "error",
583
+ "typescript/no-misused-new": "error",
584
+ "typescript/no-namespace": "error",
585
+ "typescript/no-non-null-asserted-nullish-coalescing": "error",
586
+ "typescript/no-non-null-asserted-optional-chain": "error",
587
+ "typescript/no-non-null-assertion": "error",
588
+ "typescript/no-require-imports": "error",
589
+ "typescript/no-this-alias": "error",
590
+ "typescript/no-unnecessary-type-constraint": "error",
591
+ "typescript/no-unsafe-declaration-merging": "error",
592
+ "typescript/no-unsafe-function-type": "error",
593
+ "typescript/no-wrapper-object-types": "error",
594
+ "typescript/prefer-as-const": "error",
595
+ "typescript/prefer-literal-enum-member": "error",
596
+ "typescript/prefer-namespace-keyword": "error",
597
+ "typescript/triple-slash-reference": "error",
598
+ "typescript/unified-signatures": "error",
599
+ "typescript/adjacent-overload-signatures": "error",
600
+ "typescript/array-type": [
601
+ "error",
602
+ {
603
+ "default": "array-simple"
604
+ }
605
+ ],
606
+ "typescript/ban-tslint-comment": "error",
607
+ "typescript/class-literal-property-style": "error",
608
+ "typescript/consistent-generic-constructors": "error",
609
+ "typescript/consistent-indexed-object-style": "error",
610
+ "typescript/consistent-type-assertions": "error",
611
+ "typescript/consistent-type-definitions": [
612
+ "error",
613
+ "type"
614
+ ],
615
+ "typescript/no-confusing-non-null-assertion": "error",
616
+ "typescript/no-inferrable-types": "error",
617
+ "typescript/prefer-for-of": "error",
618
+ "typescript/prefer-function-type": "error",
619
+ "typescript/consistent-type-imports": [
620
+ "error",
621
+ {
622
+ "fixStyle": "inline-type-imports"
623
+ }
624
+ ],
625
+ "typescript/no-import-type-side-effects": "error",
626
+ "typescript/no-useless-empty-export": "error",
627
+ "typescript/no-unnecessary-parameter-property-assignment": "error",
628
+ "typescript/method-signature-style": [
629
+ "error",
630
+ "property"
631
+ ],
632
+ "typescript/explicit-function-return-type": [
633
+ "error",
634
+ {
635
+ "allowExpressions": true,
636
+ "allowTypedFunctionExpressions": true,
637
+ "allowHigherOrderFunctions": true,
638
+ "allowIIFEs": true
639
+ }
640
+ ],
641
+ "typescript/explicit-member-accessibility": "error",
642
+ "typescript/prefer-enum-initializers": "error"
643
+ },
644
+ "plugins": [
645
+ "typescript"
646
+ ]
515
647
  },
516
648
  {
517
649
  "files": [
@@ -525,11 +657,12 @@
525
657
  "max-lines-per-function": "off",
526
658
  "max-statements": "off",
527
659
  "max-nested-callbacks": "off",
528
- "@typescript-eslint/explicit-function-return-type": "off",
529
- "no-magic-numbers": "off"
660
+ "no-magic-numbers": "off",
661
+ "typescript/explicit-function-return-type": "off"
530
662
  },
531
663
  "plugins": [
532
- "vitest"
664
+ "vitest",
665
+ "typescript"
533
666
  ]
534
667
  },
535
668
  {
@@ -540,9 +673,12 @@
540
673
  "max-lines": "off",
541
674
  "max-lines-per-function": "off",
542
675
  "max-statements": "off",
543
- "@typescript-eslint/explicit-function-return-type": "off",
544
- "no-magic-numbers": "off"
545
- }
676
+ "no-magic-numbers": "off",
677
+ "typescript/explicit-function-return-type": "off"
678
+ },
679
+ "plugins": [
680
+ "typescript"
681
+ ]
546
682
  },
547
683
  {
548
684
  "files": [
@@ -556,20 +692,26 @@
556
692
  "max-lines": "off",
557
693
  "max-lines-per-function": "off",
558
694
  "max-statements": "off",
559
- "@typescript-eslint/explicit-function-return-type": "off",
560
- "no-magic-numbers": "off"
561
- }
695
+ "no-magic-numbers": "off",
696
+ "typescript/explicit-function-return-type": "off"
697
+ },
698
+ "plugins": [
699
+ "typescript"
700
+ ]
562
701
  },
563
702
  {
564
703
  "files": [
565
704
  "**/*.d.ts"
566
705
  ],
567
706
  "rules": {
568
- "@typescript-eslint/explicit-function-return-type": "off",
569
- "@typescript-eslint/no-explicit-any": "off",
570
707
  "unicorn/filename-case": "off",
571
- "no-magic-numbers": "off"
572
- }
708
+ "no-magic-numbers": "off",
709
+ "typescript/explicit-function-return-type": "off",
710
+ "typescript/no-explicit-any": "off"
711
+ },
712
+ "plugins": [
713
+ "typescript"
714
+ ]
573
715
  },
574
716
  {
575
717
  "files": [
@@ -585,6 +727,7 @@
585
727
  "vitest/prefer-to-be": "error",
586
728
  "vitest/prefer-to-have-length": "error",
587
729
  "vitest/valid-expect": "error",
730
+ "vitest/valid-title": "error",
588
731
  "vitest/no-conditional-in-test": "error",
589
732
  "vitest/no-conditional-expect": "error",
590
733
  "vitest/no-standalone-expect": "error",
@@ -594,11 +737,12 @@
594
737
  "max-lines": "off",
595
738
  "max-lines-per-function": "off",
596
739
  "max-statements": "off",
597
- "@typescript-eslint/no-explicit-any": "off",
598
- "@typescript-eslint/no-non-null-assertion": "off"
740
+ "typescript/no-explicit-any": "off",
741
+ "typescript/no-non-null-assertion": "off"
599
742
  },
600
743
  "plugins": [
601
- "vitest"
744
+ "vitest",
745
+ "typescript"
602
746
  ]
603
747
  },
604
748
  {
@@ -636,26 +780,32 @@
636
780
  "max-lines": "off",
637
781
  "max-lines-per-function": "off",
638
782
  "max-statements": "off",
639
- "@typescript-eslint/no-require-imports": "off",
640
783
  "no-console": "off",
641
- "no-magic-numbers": "off"
642
- }
784
+ "no-magic-numbers": "off",
785
+ "typescript/no-require-imports": "off"
786
+ },
787
+ "plugins": [
788
+ "typescript"
789
+ ]
643
790
  },
644
791
  {
645
792
  "files": [
646
793
  "**/*.d.ts"
647
794
  ],
648
795
  "rules": {
649
- "@typescript-eslint/no-empty-interface": "off",
650
- "@typescript-eslint/no-empty-object-type": "off",
651
- "@typescript-eslint/no-explicit-any": "off",
652
- "@typescript-eslint/consistent-type-definitions": "off",
653
- "@typescript-eslint/no-namespace": "off",
654
796
  "import/no-duplicates": "off",
655
- "@typescript-eslint/explicit-function-return-type": "off",
656
797
  "unicorn/filename-case": "off",
657
- "no-unused-vars": "off"
658
- }
798
+ "no-unused-vars": "off",
799
+ "typescript/no-empty-interface": "off",
800
+ "typescript/no-empty-object-type": "off",
801
+ "typescript/no-explicit-any": "off",
802
+ "typescript/consistent-type-definitions": "off",
803
+ "typescript/no-namespace": "off",
804
+ "typescript/explicit-function-return-type": "off"
805
+ },
806
+ "plugins": [
807
+ "typescript"
808
+ ]
659
809
  },
660
810
  {
661
811
  "files": [
@@ -665,15 +815,19 @@
665
815
  "no-console": "off",
666
816
  "max-lines": "off",
667
817
  "max-lines-per-function": "off",
668
- "@typescript-eslint/explicit-function-return-type": "off",
669
- "unicorn/no-process-exit": "off"
670
- }
818
+ "unicorn/no-process-exit": "off",
819
+ "typescript/explicit-function-return-type": "off"
820
+ },
821
+ "plugins": [
822
+ "typescript"
823
+ ]
671
824
  },
672
825
  {
673
826
  "files": [
674
827
  "**/*.{md,mdx}"
675
828
  ],
676
829
  "rules": {
830
+ "no-unused-expressions": "error",
677
831
  "react/react-in-jsx-scope": "off"
678
832
  },
679
833
  "globals": {
@@ -688,7 +842,10 @@
688
842
  "no-unused-expressions": "off",
689
843
  "no-unused-vars": "off",
690
844
  "unicode-bom": "off"
691
- }
845
+ },
846
+ "plugins": [
847
+ "typescript"
848
+ ]
692
849
  }
693
850
  ]
694
851
  }