eslint-config-setup 0.3.3 → 0.4.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.
@@ -24,9 +24,10 @@ export default [
24
24
  // TypeScript parser setup
25
25
  ...tseslint.configs.strictTypeChecked.slice(0, 2),
26
26
 
27
- // Base rules — all effective rules for *.ts files
27
+ // Base rules — all effective rules for TS plus shared JS/TS rules
28
28
  {
29
29
  name: "eslint-config-setup/base",
30
+ ignores: ["**/*.{md,mdx}"],
30
31
  plugins: {
31
32
  "@cspell": cspellPlugin,
32
33
  "@typescript-eslint": tseslint.plugin,
@@ -68,7 +69,7 @@ export default [
68
69
  "@typescript-eslint/ban-ts-comment": [
69
70
  "error",
70
71
  {
71
- "minimumDescriptionLength": 10
72
+ "ts-expect-error": "allow-with-description"
72
73
  }
73
74
  ],
74
75
  "@typescript-eslint/ban-tslint-comment": "error",
@@ -76,7 +77,10 @@ export default [
76
77
  "@typescript-eslint/consistent-generic-constructors": "error",
77
78
  "@typescript-eslint/consistent-indexed-object-style": "error",
78
79
  "@typescript-eslint/consistent-type-assertions": "error",
79
- "@typescript-eslint/consistent-type-definitions": "error",
80
+ "@typescript-eslint/consistent-type-definitions": [
81
+ "error",
82
+ "type"
83
+ ],
80
84
  "@typescript-eslint/consistent-type-exports": [
81
85
  "error",
82
86
  {
@@ -86,10 +90,14 @@ export default [
86
90
  "@typescript-eslint/consistent-type-imports": [
87
91
  "error",
88
92
  {
89
- "fixStyle": "inline-type-imports"
93
+ "fixStyle": "separate-type-imports"
90
94
  }
91
95
  ],
92
96
  "@typescript-eslint/dot-notation": "error",
97
+ "@typescript-eslint/method-signature-style": [
98
+ "error",
99
+ "property"
100
+ ],
93
101
  "@typescript-eslint/no-array-constructor": "error",
94
102
  "@typescript-eslint/no-array-delete": "error",
95
103
  "@typescript-eslint/no-base-to-string": "error",
@@ -101,10 +109,21 @@ export default [
101
109
  "@typescript-eslint/no-dynamic-delete": "error",
102
110
  "@typescript-eslint/no-empty-function": "error",
103
111
  "@typescript-eslint/no-empty-object-type": "error",
104
- "@typescript-eslint/no-explicit-any": "error",
112
+ "@typescript-eslint/no-explicit-any": [
113
+ "warn",
114
+ {
115
+ "fixToUnknown": true
116
+ }
117
+ ],
105
118
  "@typescript-eslint/no-extra-non-null-assertion": "error",
106
119
  "@typescript-eslint/no-extraneous-class": "error",
107
- "@typescript-eslint/no-floating-promises": "error",
120
+ "@typescript-eslint/no-floating-promises": [
121
+ "error",
122
+ {
123
+ "checkThenables": true,
124
+ "ignoreIIFE": true
125
+ }
126
+ ],
108
127
  "@typescript-eslint/no-for-in-array": "error",
109
128
  "@typescript-eslint/no-implied-eval": "error",
110
129
  "@typescript-eslint/no-import-type-side-effects": "error",
@@ -155,6 +174,7 @@ export default [
155
174
  "@typescript-eslint/no-unsafe-function-type": "error",
156
175
  "@typescript-eslint/no-unsafe-member-access": "error",
157
176
  "@typescript-eslint/no-unsafe-return": "error",
177
+ "@typescript-eslint/no-unsafe-type-assertion": "error",
158
178
  "@typescript-eslint/no-unsafe-unary-minus": "error",
159
179
  "@typescript-eslint/no-unused-expressions": "error",
160
180
  "@typescript-eslint/no-unused-vars": [
@@ -185,11 +205,19 @@ export default [
185
205
  "@typescript-eslint/prefer-nullish-coalescing": "error",
186
206
  "@typescript-eslint/prefer-optional-chain": "error",
187
207
  "@typescript-eslint/prefer-promise-reject-errors": "error",
208
+ "@typescript-eslint/prefer-readonly": "warn",
188
209
  "@typescript-eslint/prefer-reduce-type-parameter": "error",
189
210
  "@typescript-eslint/prefer-regexp-exec": "error",
190
211
  "@typescript-eslint/prefer-return-this-type": "error",
191
212
  "@typescript-eslint/prefer-string-starts-ends-with": "error",
213
+ "@typescript-eslint/promise-function-async": "error",
192
214
  "@typescript-eslint/related-getter-setter-pairs": "error",
215
+ "@typescript-eslint/require-array-sort-compare": [
216
+ "error",
217
+ {
218
+ "ignoreStringArrays": true
219
+ }
220
+ ],
193
221
  "@typescript-eslint/require-await": "error",
194
222
  "@typescript-eslint/restrict-plus-operands": [
195
223
  "error",
@@ -219,6 +247,13 @@ export default [
219
247
  }
220
248
  ],
221
249
  "@typescript-eslint/strict-void-return": "error",
250
+ "@typescript-eslint/switch-exhaustiveness-check": [
251
+ "error",
252
+ {
253
+ "allowDefaultCaseForExhaustiveSwitch": false,
254
+ "requireDefaultForNonUnion": true
255
+ }
256
+ ],
222
257
  "@typescript-eslint/triple-slash-reference": "error",
223
258
  "@typescript-eslint/unbound-method": "error",
224
259
  "@typescript-eslint/unified-signatures": "error",
@@ -262,17 +297,35 @@ export default [
262
297
  "maxDepth": 3
263
298
  }
264
299
  ],
265
- "import/no-duplicates": [
300
+ "import/no-duplicates": "error",
301
+ "import/no-empty-named-blocks": "error",
302
+ "import/no-extraneous-dependencies": [
266
303
  "error",
267
304
  {
268
- "prefer-inline": true
305
+ "includeTypes": true
269
306
  }
270
307
  ],
271
- "import/no-empty-named-blocks": "error",
272
308
  "import/no-mutable-exports": "error",
273
309
  "import/no-named-as-default": "error",
274
310
  "import/no-named-as-default-member": "error",
311
+ "import/no-named-default": "error",
275
312
  "import/no-self-import": "error",
313
+ "import/no-unassigned-import": [
314
+ "error",
315
+ {
316
+ "allow": [
317
+ "@babel/polyfill",
318
+ "**/register",
319
+ "**/register.*",
320
+ "**/register/**",
321
+ "**/register/**.*",
322
+ "**/*.css",
323
+ "**/*.scss",
324
+ "**/*.sass",
325
+ "**/*.less"
326
+ ]
327
+ }
328
+ ],
276
329
  "import/no-useless-path-segments": "error",
277
330
  "jsdoc/check-access": "error",
278
331
  "jsdoc/check-alignment": "error",
@@ -360,6 +413,7 @@ export default [
360
413
  "no-extra-boolean-cast": "error",
361
414
  "no-fallthrough": "error",
362
415
  "no-global-assign": "error",
416
+ "no-implicit-globals": "error",
363
417
  "no-irregular-whitespace": "error",
364
418
  "no-iterator": "error",
365
419
  "no-labels": "error",
@@ -378,10 +432,19 @@ export default [
378
432
  "no-proto": "error",
379
433
  "no-prototype-builtins": "error",
380
434
  "no-regex-spaces": "error",
435
+ "no-return-assign": [
436
+ "error",
437
+ "always"
438
+ ],
381
439
  "no-script-url": "error",
382
440
  "no-self-assign": "error",
383
441
  "no-self-compare": "error",
384
- "no-sequences": "error",
442
+ "no-sequences": [
443
+ "error",
444
+ {
445
+ "allowInParentheses": false
446
+ }
447
+ ],
385
448
  "no-shadow-restricted-names": "error",
386
449
  "no-sparse-arrays": "error",
387
450
  "no-template-curly-in-string": "error",
@@ -395,12 +458,25 @@ export default [
395
458
  "no-useless-assignment": "error",
396
459
  "no-useless-call": "error",
397
460
  "no-useless-catch": "error",
398
- "no-useless-computed-key": "error",
461
+ "no-useless-computed-key": [
462
+ "error",
463
+ {
464
+ "enforceForClassMembers": true
465
+ }
466
+ ],
399
467
  "no-useless-concat": "error",
400
468
  "no-useless-escape": "error",
401
469
  "no-useless-rename": "error",
402
470
  "no-useless-return": "error",
403
471
  "no-var": "error",
472
+ "object-shorthand": [
473
+ "error",
474
+ "always",
475
+ {
476
+ "avoidExplicitReturnArrows": true,
477
+ "avoidQuotes": true
478
+ }
479
+ ],
404
480
  "perfectionist/sort-exports": "error",
405
481
  "perfectionist/sort-imports": [
406
482
  "error",
@@ -413,12 +489,13 @@ export default [
413
489
  "perfectionist/sort-named-imports": "error",
414
490
  "perfectionist/sort-union-types": "error",
415
491
  "prefer-const": "error",
492
+ "prefer-numeric-literals": "error",
416
493
  "prefer-object-has-own": "error",
417
494
  "prefer-object-spread": "error",
418
495
  "prefer-regex-literals": "error",
419
496
  "prefer-rest-params": "error",
420
497
  "prefer-spread": "error",
421
- "prefer-template": "error",
498
+ "prefer-template": "warn",
422
499
  "preserve-caught-error": "error",
423
500
  "radix": "error",
424
501
  "regexp/confusing-quantifier": "warn",
@@ -535,15 +612,28 @@ export default [
535
612
  "unicorn/consistent-date-clone": "error",
536
613
  "unicorn/consistent-empty-array-spread": "error",
537
614
  "unicorn/consistent-existence-index-check": "error",
615
+ "unicorn/consistent-function-scoping": "warn",
538
616
  "unicorn/error-message": "error",
617
+ "unicorn/filename-case": [
618
+ "error",
619
+ {
620
+ "cases": {
621
+ "camelCase": true,
622
+ "pascalCase": true,
623
+ "kebabCase": true
624
+ }
625
+ }
626
+ ],
539
627
  "unicorn/new-for-builtins": "error",
540
628
  "unicorn/no-abusive-eslint-disable": "error",
541
629
  "unicorn/no-accessor-recursion": "error",
542
630
  "unicorn/no-anonymous-default-export": "error",
543
631
  "unicorn/no-array-callback-reference": "error",
544
632
  "unicorn/no-array-method-this-argument": "error",
633
+ "unicorn/no-array-reduce": "warn",
545
634
  "unicorn/no-await-expression-member": "error",
546
635
  "unicorn/no-await-in-promise-methods": "error",
636
+ "unicorn/no-for-loop": "warn",
547
637
  "unicorn/no-instanceof-builtins": "error",
548
638
  "unicorn/no-invalid-fetch-options": "error",
549
639
  "unicorn/no-invalid-remove-event-listener": "error",
@@ -561,7 +651,12 @@ export default [
561
651
  "unicorn/no-useless-length-check": "error",
562
652
  "unicorn/no-useless-promise-resolve-reject": "error",
563
653
  "unicorn/no-useless-spread": "error",
564
- "unicorn/no-useless-undefined": "error",
654
+ "unicorn/no-useless-undefined": [
655
+ "warn",
656
+ {
657
+ "checkArguments": false
658
+ }
659
+ ],
565
660
  "unicorn/no-zero-fractions": "error",
566
661
  "unicorn/numeric-separators-style": "error",
567
662
  "unicorn/prefer-array-find": "error",
@@ -571,6 +666,7 @@ export default [
571
666
  "unicorn/prefer-array-some": "error",
572
667
  "unicorn/prefer-at": "error",
573
668
  "unicorn/prefer-date-now": "error",
669
+ "unicorn/prefer-dom-node-dataset": "error",
574
670
  "unicorn/prefer-export-from": [
575
671
  "error",
576
672
  {
@@ -602,8 +698,19 @@ export default [
602
698
  "unicorn/text-encoding-identifier-case": "error",
603
699
  "unicorn/throw-new-error": "error",
604
700
  "unused-imports/no-unused-imports": "error",
605
- "use-isnan": "error",
606
- "valid-typeof": "error",
701
+ "use-isnan": [
702
+ "error",
703
+ {
704
+ "enforceForIndexOf": true,
705
+ "enforceForSwitchCase": true
706
+ }
707
+ ],
708
+ "valid-typeof": [
709
+ "error",
710
+ {
711
+ "requireStringLiterals": true
712
+ }
713
+ ],
607
714
  "yoda": "error"
608
715
  },
609
716
  },
@@ -613,46 +720,91 @@ export default [
613
720
  name: "eslint-config-setup/js-compat",
614
721
  files: ["**/*.{js,mjs,cjs}"],
615
722
  rules: {
723
+ "@typescript-eslint/adjacent-overload-signatures": "off",
724
+ "@typescript-eslint/array-type": "off",
616
725
  "@typescript-eslint/await-thenable": "off",
726
+ "@typescript-eslint/ban-ts-comment": "off",
727
+ "@typescript-eslint/ban-tslint-comment": "off",
728
+ "@typescript-eslint/class-literal-property-style": "off",
729
+ "@typescript-eslint/consistent-generic-constructors": "off",
730
+ "@typescript-eslint/consistent-indexed-object-style": "off",
617
731
  "@typescript-eslint/consistent-return": "off",
732
+ "@typescript-eslint/consistent-type-assertions": "off",
733
+ "@typescript-eslint/consistent-type-definitions": "off",
618
734
  "@typescript-eslint/consistent-type-exports": "off",
735
+ "@typescript-eslint/consistent-type-imports": "off",
619
736
  "@typescript-eslint/dot-notation": "off",
737
+ "@typescript-eslint/method-signature-style": "off",
620
738
  "@typescript-eslint/naming-convention": "off",
739
+ "@typescript-eslint/no-array-constructor": "off",
621
740
  "@typescript-eslint/no-array-delete": "off",
622
741
  "@typescript-eslint/no-base-to-string": "off",
742
+ "@typescript-eslint/no-confusing-non-null-assertion": "off",
623
743
  "@typescript-eslint/no-confusing-void-expression": "off",
624
744
  "@typescript-eslint/no-deprecated": "off",
745
+ "@typescript-eslint/no-duplicate-enum-values": "off",
625
746
  "@typescript-eslint/no-duplicate-type-constituents": "off",
747
+ "@typescript-eslint/no-dynamic-delete": "off",
748
+ "@typescript-eslint/no-empty-function": "off",
749
+ "@typescript-eslint/no-empty-object-type": "off",
750
+ "@typescript-eslint/no-explicit-any": "off",
751
+ "@typescript-eslint/no-extra-non-null-assertion": "off",
752
+ "@typescript-eslint/no-extraneous-class": "off",
626
753
  "@typescript-eslint/no-floating-promises": "off",
627
754
  "@typescript-eslint/no-for-in-array": "off",
628
755
  "@typescript-eslint/no-implied-eval": "off",
756
+ "@typescript-eslint/no-import-type-side-effects": "off",
757
+ "@typescript-eslint/no-inferrable-types": "off",
758
+ "@typescript-eslint/no-invalid-void-type": "off",
629
759
  "@typescript-eslint/no-meaningless-void-operator": "off",
760
+ "@typescript-eslint/no-misused-new": "off",
630
761
  "@typescript-eslint/no-misused-promises": "off",
631
762
  "@typescript-eslint/no-misused-spread": "off",
632
763
  "@typescript-eslint/no-mixed-enums": "off",
764
+ "@typescript-eslint/no-namespace": "off",
765
+ "@typescript-eslint/no-non-null-asserted-nullish-coalescing": "off",
766
+ "@typescript-eslint/no-non-null-asserted-optional-chain": "off",
767
+ "@typescript-eslint/no-non-null-assertion": "off",
633
768
  "@typescript-eslint/no-redundant-type-constituents": "off",
769
+ "@typescript-eslint/no-require-imports": "off",
770
+ "@typescript-eslint/no-shadow": "off",
771
+ "@typescript-eslint/no-this-alias": "off",
634
772
  "@typescript-eslint/no-unnecessary-boolean-literal-compare": "off",
635
773
  "@typescript-eslint/no-unnecessary-condition": "off",
774
+ "@typescript-eslint/no-unnecessary-parameter-property-assignment": "off",
636
775
  "@typescript-eslint/no-unnecessary-qualifier": "off",
637
776
  "@typescript-eslint/no-unnecessary-template-expression": "off",
638
777
  "@typescript-eslint/no-unnecessary-type-arguments": "off",
639
778
  "@typescript-eslint/no-unnecessary-type-assertion": "off",
779
+ "@typescript-eslint/no-unnecessary-type-constraint": "off",
640
780
  "@typescript-eslint/no-unnecessary-type-conversion": "off",
641
781
  "@typescript-eslint/no-unnecessary-type-parameters": "off",
642
782
  "@typescript-eslint/no-unsafe-argument": "off",
643
783
  "@typescript-eslint/no-unsafe-assignment": "off",
644
784
  "@typescript-eslint/no-unsafe-call": "off",
785
+ "@typescript-eslint/no-unsafe-declaration-merging": "off",
645
786
  "@typescript-eslint/no-unsafe-enum-comparison": "off",
787
+ "@typescript-eslint/no-unsafe-function-type": "off",
646
788
  "@typescript-eslint/no-unsafe-member-access": "off",
647
789
  "@typescript-eslint/no-unsafe-return": "off",
648
790
  "@typescript-eslint/no-unsafe-type-assertion": "off",
649
791
  "@typescript-eslint/no-unsafe-unary-minus": "off",
792
+ "@typescript-eslint/no-unused-expressions": "off",
793
+ "@typescript-eslint/no-unused-vars": "off",
794
+ "@typescript-eslint/no-useless-constructor": "off",
650
795
  "@typescript-eslint/no-useless-default-assignment": "off",
796
+ "@typescript-eslint/no-useless-empty-export": "off",
797
+ "@typescript-eslint/no-wrapper-object-types": "off",
651
798
  "@typescript-eslint/non-nullable-type-assertion-style": "off",
652
799
  "@typescript-eslint/only-throw-error": "off",
800
+ "@typescript-eslint/prefer-as-const": "off",
653
801
  "@typescript-eslint/prefer-destructuring": "off",
654
802
  "@typescript-eslint/prefer-find": "off",
803
+ "@typescript-eslint/prefer-for-of": "off",
804
+ "@typescript-eslint/prefer-function-type": "off",
655
805
  "@typescript-eslint/prefer-includes": "off",
806
+ "@typescript-eslint/prefer-literal-enum-member": "off",
807
+ "@typescript-eslint/prefer-namespace-keyword": "off",
656
808
  "@typescript-eslint/prefer-nullish-coalescing": "off",
657
809
  "@typescript-eslint/prefer-optional-chain": "off",
658
810
  "@typescript-eslint/prefer-promise-reject-errors": "off",
@@ -672,33 +824,47 @@ export default [
672
824
  "@typescript-eslint/strict-boolean-expressions": "off",
673
825
  "@typescript-eslint/strict-void-return": "off",
674
826
  "@typescript-eslint/switch-exhaustiveness-check": "off",
827
+ "@typescript-eslint/triple-slash-reference": "off",
675
828
  "@typescript-eslint/unbound-method": "off",
829
+ "@typescript-eslint/unified-signatures": "off",
676
830
  "@typescript-eslint/use-unknown-in-catch-callback-variable": "off",
677
831
  "constructor-super": "error",
832
+ "dot-notation": "off",
678
833
  "getter-return": "error",
834
+ "no-array-constructor": "off",
679
835
  "no-class-assign": "error",
680
836
  "no-const-assign": "error",
681
837
  "no-dupe-args": "error",
682
838
  "no-dupe-class-members": "error",
683
839
  "no-dupe-keys": "error",
840
+ "no-empty-function": "off",
684
841
  "no-func-assign": "error",
842
+ "no-implied-eval": "off",
685
843
  "no-import-assign": "error",
686
844
  "no-new-native-nonconstructor": "error",
687
845
  "no-new-symbol": "off",
688
846
  "no-obj-calls": "error",
689
847
  "no-redeclare": "error",
848
+ "no-return-await": "off",
690
849
  "no-setter-return": "error",
850
+ "no-shadow": "off",
691
851
  "no-this-before-super": "error",
852
+ "no-throw-literal": "off",
692
853
  "no-undef": "error",
693
854
  "no-unreachable": "error",
694
855
  "no-unsafe-negation": "error",
856
+ "no-unused-expressions": "off",
857
+ "no-unused-vars": "error",
858
+ "no-useless-constructor": "off",
695
859
  "no-with": "error",
696
860
  "prefer-const": [
697
861
  "error",
698
862
  {
699
863
  "destructuring": "all"
700
864
  }
701
- ]
865
+ ],
866
+ "prefer-promise-reject-errors": "off",
867
+ "require-await": "off"
702
868
  },
703
869
  },
704
870
 
@@ -936,7 +1102,132 @@ export default [
936
1102
  // Markdown/MDX code block linting
937
1103
  {
938
1104
  ...mdxPlugin.flatCodeBlocks,
1105
+ languageOptions: {
1106
+ ...mdxPlugin.flatCodeBlocks.languageOptions,
1107
+ parserOptions: {
1108
+ ...mdxPlugin.flatCodeBlocks.languageOptions?.parserOptions,
1109
+ projectService: false,
1110
+ },
1111
+ },
939
1112
  rules: {
1113
+ ...{
1114
+ "@typescript-eslint/adjacent-overload-signatures": "off",
1115
+ "@typescript-eslint/array-type": "off",
1116
+ "@typescript-eslint/await-thenable": "off",
1117
+ "@typescript-eslint/ban-ts-comment": "off",
1118
+ "@typescript-eslint/ban-tslint-comment": "off",
1119
+ "@typescript-eslint/class-literal-property-style": "off",
1120
+ "@typescript-eslint/consistent-generic-constructors": "off",
1121
+ "@typescript-eslint/consistent-indexed-object-style": "off",
1122
+ "@typescript-eslint/consistent-type-assertions": "off",
1123
+ "@typescript-eslint/consistent-type-definitions": "off",
1124
+ "@typescript-eslint/consistent-type-exports": "off",
1125
+ "@typescript-eslint/consistent-type-imports": "off",
1126
+ "@typescript-eslint/dot-notation": "off",
1127
+ "@typescript-eslint/method-signature-style": "off",
1128
+ "@typescript-eslint/no-array-constructor": "off",
1129
+ "@typescript-eslint/no-array-delete": "off",
1130
+ "@typescript-eslint/no-base-to-string": "off",
1131
+ "@typescript-eslint/no-confusing-non-null-assertion": "off",
1132
+ "@typescript-eslint/no-confusing-void-expression": "off",
1133
+ "@typescript-eslint/no-deprecated": "off",
1134
+ "@typescript-eslint/no-duplicate-enum-values": "off",
1135
+ "@typescript-eslint/no-duplicate-type-constituents": "off",
1136
+ "@typescript-eslint/no-dynamic-delete": "off",
1137
+ "@typescript-eslint/no-empty-function": "off",
1138
+ "@typescript-eslint/no-empty-object-type": "off",
1139
+ "@typescript-eslint/no-explicit-any": "off",
1140
+ "@typescript-eslint/no-extra-non-null-assertion": "off",
1141
+ "@typescript-eslint/no-extraneous-class": "off",
1142
+ "@typescript-eslint/no-floating-promises": "off",
1143
+ "@typescript-eslint/no-for-in-array": "off",
1144
+ "@typescript-eslint/no-implied-eval": "off",
1145
+ "@typescript-eslint/no-import-type-side-effects": "off",
1146
+ "@typescript-eslint/no-inferrable-types": "off",
1147
+ "@typescript-eslint/no-invalid-void-type": "off",
1148
+ "@typescript-eslint/no-meaningless-void-operator": "off",
1149
+ "@typescript-eslint/no-misused-new": "off",
1150
+ "@typescript-eslint/no-misused-promises": "off",
1151
+ "@typescript-eslint/no-misused-spread": "off",
1152
+ "@typescript-eslint/no-mixed-enums": "off",
1153
+ "@typescript-eslint/no-namespace": "off",
1154
+ "@typescript-eslint/no-non-null-asserted-nullish-coalescing": "off",
1155
+ "@typescript-eslint/no-non-null-asserted-optional-chain": "off",
1156
+ "@typescript-eslint/no-non-null-assertion": "off",
1157
+ "@typescript-eslint/no-redundant-type-constituents": "off",
1158
+ "@typescript-eslint/no-require-imports": "off",
1159
+ "@typescript-eslint/no-shadow": "off",
1160
+ "@typescript-eslint/no-this-alias": "off",
1161
+ "@typescript-eslint/no-unnecessary-boolean-literal-compare": "off",
1162
+ "@typescript-eslint/no-unnecessary-condition": "off",
1163
+ "@typescript-eslint/no-unnecessary-parameter-property-assignment": "off",
1164
+ "@typescript-eslint/no-unnecessary-qualifier": "off",
1165
+ "@typescript-eslint/no-unnecessary-template-expression": "off",
1166
+ "@typescript-eslint/no-unnecessary-type-arguments": "off",
1167
+ "@typescript-eslint/no-unnecessary-type-assertion": "off",
1168
+ "@typescript-eslint/no-unnecessary-type-constraint": "off",
1169
+ "@typescript-eslint/no-unnecessary-type-conversion": "off",
1170
+ "@typescript-eslint/no-unnecessary-type-parameters": "off",
1171
+ "@typescript-eslint/no-unsafe-argument": "off",
1172
+ "@typescript-eslint/no-unsafe-assignment": "off",
1173
+ "@typescript-eslint/no-unsafe-call": "off",
1174
+ "@typescript-eslint/no-unsafe-declaration-merging": "off",
1175
+ "@typescript-eslint/no-unsafe-enum-comparison": "off",
1176
+ "@typescript-eslint/no-unsafe-function-type": "off",
1177
+ "@typescript-eslint/no-unsafe-member-access": "off",
1178
+ "@typescript-eslint/no-unsafe-return": "off",
1179
+ "@typescript-eslint/no-unsafe-type-assertion": "off",
1180
+ "@typescript-eslint/no-unsafe-unary-minus": "off",
1181
+ "@typescript-eslint/no-unused-expressions": "off",
1182
+ "@typescript-eslint/no-unused-vars": "off",
1183
+ "@typescript-eslint/no-useless-constructor": "off",
1184
+ "@typescript-eslint/no-useless-default-assignment": "off",
1185
+ "@typescript-eslint/no-useless-empty-export": "off",
1186
+ "@typescript-eslint/no-wrapper-object-types": "off",
1187
+ "@typescript-eslint/non-nullable-type-assertion-style": "off",
1188
+ "@typescript-eslint/only-throw-error": "off",
1189
+ "@typescript-eslint/prefer-as-const": "off",
1190
+ "@typescript-eslint/prefer-find": "off",
1191
+ "@typescript-eslint/prefer-for-of": "off",
1192
+ "@typescript-eslint/prefer-function-type": "off",
1193
+ "@typescript-eslint/prefer-includes": "off",
1194
+ "@typescript-eslint/prefer-literal-enum-member": "off",
1195
+ "@typescript-eslint/prefer-namespace-keyword": "off",
1196
+ "@typescript-eslint/prefer-nullish-coalescing": "off",
1197
+ "@typescript-eslint/prefer-optional-chain": "off",
1198
+ "@typescript-eslint/prefer-promise-reject-errors": "off",
1199
+ "@typescript-eslint/prefer-readonly": "off",
1200
+ "@typescript-eslint/prefer-reduce-type-parameter": "off",
1201
+ "@typescript-eslint/prefer-regexp-exec": "off",
1202
+ "@typescript-eslint/prefer-return-this-type": "off",
1203
+ "@typescript-eslint/prefer-string-starts-ends-with": "off",
1204
+ "@typescript-eslint/promise-function-async": "off",
1205
+ "@typescript-eslint/related-getter-setter-pairs": "off",
1206
+ "@typescript-eslint/require-array-sort-compare": "off",
1207
+ "@typescript-eslint/require-await": "off",
1208
+ "@typescript-eslint/restrict-plus-operands": "off",
1209
+ "@typescript-eslint/restrict-template-expressions": "off",
1210
+ "@typescript-eslint/return-await": "off",
1211
+ "@typescript-eslint/strict-boolean-expressions": "off",
1212
+ "@typescript-eslint/strict-void-return": "off",
1213
+ "@typescript-eslint/switch-exhaustiveness-check": "off",
1214
+ "@typescript-eslint/triple-slash-reference": "off",
1215
+ "@typescript-eslint/unbound-method": "off",
1216
+ "@typescript-eslint/unified-signatures": "off",
1217
+ "@typescript-eslint/use-unknown-in-catch-callback-variable": "off",
1218
+ "dot-notation": "off",
1219
+ "no-array-constructor": "off",
1220
+ "no-empty-function": "off",
1221
+ "no-implied-eval": "off",
1222
+ "no-return-await": "off",
1223
+ "no-shadow": "off",
1224
+ "no-throw-literal": "off",
1225
+ "no-useless-constructor": "off",
1226
+ "prefer-promise-reject-errors": "off",
1227
+ "require-await": "off",
1228
+ "strict": "off",
1229
+ "unicode-bom": "off"
1230
+ },
940
1231
  ...mdxPlugin.flatCodeBlocks.rules,
941
1232
  "eol-last": "off",
942
1233
  "no-undef": "off",
package/dist/index.d.ts CHANGED
@@ -1,18 +1,7 @@
1
- import { C as ConfigOptions, F as FlatConfigArray, O as OxlintConfigOptions, a as OxlintConfigResult, R as RuleSeverity, b as RuleOptions } from './types-CAUUIuJR.js';
2
- export { c as RuleScope } from './types-CAUUIuJR.js';
1
+ import { F as FlatConfigArray, R as RuleSeverity, a as RuleOptions, C as ConfigOptions, O as OxlintConfigOptions, b as OxlintConfigResult } from './types-CAO1PbsB.js';
2
+ export { c as RuleScope } from './types-CAO1PbsB.js';
3
3
  import 'eslint';
4
4
 
5
- /**
6
- * Loads a pre-generated ESLint config by dynamically importing the hashed file.
7
- * The hash is computed from the options using the same algorithm as the build.
8
- */
9
- declare function getEslintConfig(opts?: ConfigOptions): Promise<FlatConfigArray>;
10
- /**
11
- * Loads a pre-generated OxLint config from the hashed JSON file.
12
- * Only `react`, `node`, and `ai` flags are relevant — `oxlint` is ignored.
13
- */
14
- declare function getOxlintConfig(opts?: OxlintConfigOptions): OxlintConfigResult;
15
-
16
5
  /**
17
6
  * Change the severity of a rule across all config blocks, preserving options.
18
7
  */
@@ -49,4 +38,15 @@ declare function bitmaskToHash(mask: number): string;
49
38
  /** Convenience: options → filename (without path prefix). */
50
39
  declare function optionsToFilename(opts: ConfigOptions): string;
51
40
 
41
+ /**
42
+ * Loads a pre-generated ESLint config by dynamically importing the hashed file.
43
+ * The hash is computed from the options using the same algorithm as the build.
44
+ */
45
+ declare function getEslintConfig(opts?: ConfigOptions): Promise<FlatConfigArray>;
46
+ /**
47
+ * Loads a pre-generated OxLint config from the hashed JSON file.
48
+ * Only `react`, `node`, and `ai` flags are relevant — `oxlint` is ignored.
49
+ */
50
+ declare function getOxlintConfig(opts?: OxlintConfigOptions): OxlintConfigResult;
51
+
52
52
  export { ConfigOptions, FlatConfigArray, OxlintConfigOptions, OxlintConfigResult, RuleOptions, RuleSeverity, addRule, bitmaskToHash, configureRule, disableAllRulesBut, disableRule, getEslintConfig, getOxlintConfig, optionsToBitmask, optionsToFilename, setRuleSeverity };