eslint-config-setup 0.3.2 → 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.
@@ -14,7 +14,6 @@ import packageJsonPlugin from "eslint-plugin-package-json"
14
14
  import perfectionistPlugin from "eslint-plugin-perfectionist"
15
15
  import playwrightPlugin from "eslint-plugin-playwright"
16
16
  import reactEffectPlugin from "eslint-plugin-react-you-might-not-need-an-effect"
17
- import reactHooksPlugin from "eslint-plugin-react-hooks"
18
17
  import reactRefreshPlugin from "eslint-plugin-react-refresh"
19
18
  import regexpPlugin from "eslint-plugin-regexp"
20
19
  import securityPlugin from "eslint-plugin-security"
@@ -27,13 +26,100 @@ import unicornPlugin from "eslint-plugin-unicorn"
27
26
  import unusedImportsPlugin from "eslint-plugin-unused-imports"
28
27
  import vitestPlugin from "@vitest/eslint-plugin"
29
28
 
29
+ // React compat plugin — merges @eslint-react sub-plugins into a single `react/` namespace
30
+ // and aliases rules to legacy eslint-plugin-react names for OxLint compatibility.
31
+ const reactCompatPlugin = (() => {
32
+ const core = eslintReactPlugin.rules
33
+ const select = (prefix) => Object.fromEntries(
34
+ Object.entries(core)
35
+ .filter(([name]) => name.startsWith(prefix))
36
+ .map(([name, rule]) => [name.slice(prefix.length), rule]),
37
+ )
38
+ const dom = select("dom-")
39
+ const jsx = select("jsx-")
40
+ const naming = select("naming-convention-")
41
+ const rsc = select("rsc-")
42
+ const webApi = select("web-api-")
43
+
44
+ // Legacy aliases: legacy name → [source, original name]
45
+ const aliases = {
46
+ "jsx-key": [core, "no-missing-key"],
47
+ "jsx-key-before-spread": [jsx, "no-key-after-spread"],
48
+ "jsx-no-constructed-context-values": [core, "no-unstable-context-value"],
49
+ "jsx-no-leaked-render": [core, "no-leaked-conditional-rendering"],
50
+ "jsx-no-useless-fragment": [jsx, "no-useless-fragment"],
51
+ "no-object-type-as-default-prop": [core, "no-unstable-default-props"],
52
+ "no-unstable-nested-components": [core, "no-nested-component-definitions"],
53
+ "display-name": [core, "no-missing-component-display-name"],
54
+ "forward-ref-uses-ref": [core, "no-forward-ref"],
55
+ "destructuring-assignment": [core, "prefer-destructuring-assignment"],
56
+ "no-did-mount-set-state": [core, "no-set-state-in-component-did-mount"],
57
+ "no-did-update-set-state": [core, "no-set-state-in-component-did-update"],
58
+ "no-will-update-set-state": [core, "no-set-state-in-component-will-update"],
59
+ "hook-use-state": [core, "use-state"],
60
+ "no-danger": [dom, "no-dangerously-set-innerhtml"],
61
+ "no-danger-with-children": [dom, "no-dangerously-set-innerhtml-with-children"],
62
+ "no-find-dom-node": [dom, "no-find-dom-node"],
63
+ "no-namespace": [jsx, "no-namespace"],
64
+ "no-render-return-value": [dom, "no-render-return-value"],
65
+ "jsx-no-script-url": [dom, "no-script-url"],
66
+ "jsx-no-target-blank": [dom, "no-unsafe-target-blank"],
67
+ "no-unknown-property": [dom, "no-unknown-property"],
68
+ "void-dom-elements-no-children": [dom, "no-void-elements-with-children"],
69
+ "button-has-type": [dom, "no-missing-button-type"],
70
+ "iframe-missing-sandbox": [dom, "no-missing-iframe-sandbox"],
71
+ "style-prop-object": [dom, "no-string-style-prop"],
72
+ }
73
+
74
+ // Identical-name aliases (core rules where legacy name = @eslint-react name)
75
+ const identicalCore = [
76
+ "no-access-state-in-setstate", "no-array-index-key",
77
+ "no-direct-mutation-state", "no-redundant-should-component-update",
78
+ "no-unused-class-component-members", "no-unused-state",
79
+ ]
80
+ for (const n of identicalCore) aliases[n] = [core, n]
81
+ aliases["no-children-prop"] = [jsx, "no-children-prop"]
82
+ aliases["jsx-no-comment-textnodes"] = [jsx, "no-comment-textnodes"]
83
+
84
+ // Build aliased originals set
85
+ const aliasedCore = new Set()
86
+ for (const [src, name] of Object.values(aliases)) {
87
+ if (src === core) aliasedCore.add(name)
88
+ else if (src === dom) aliasedCore.add("dom-" + name)
89
+ else if (src === jsx) aliasedCore.add("jsx-" + name)
90
+ else if (src === naming) aliasedCore.add("naming-convention-" + name)
91
+ else if (src === rsc) aliasedCore.add("rsc-" + name)
92
+ else if (src === webApi) aliasedCore.add("web-api-" + name)
93
+ }
94
+ const rules = {}
95
+
96
+ // Core rules (skip aliased originals)
97
+ for (const [n, r] of Object.entries(core)) { if (!aliasedCore.has(n)) rules[n] = r }
98
+
99
+ // Sub-plugin rules (skip aliased + prefer-namespace-import collision)
100
+ const subs = [[dom, new Set(['prefer-namespace-import'])], [jsx], [webApi], [naming], [rsc]]
101
+ for (const [src, skip] of subs) {
102
+ for (const [n, r] of Object.entries(src)) {
103
+ if (skip && skip.has(n)) continue
104
+ if (Object.values(aliases).some(([s, o]) => s === src && o === n)) continue
105
+ rules[n] = r
106
+ }
107
+ }
108
+
109
+ // Add legacy aliases
110
+ for (const [legacy, [src, orig]] of Object.entries(aliases)) rules[legacy] = src[orig]
111
+
112
+ return { meta: { name: "react-compat", version: "1.0.0" }, rules }
113
+ })()
114
+
30
115
  export default [
31
116
  // TypeScript parser setup
32
117
  ...tseslint.configs.strictTypeChecked.slice(0, 2),
33
118
 
34
- // Base rules — all effective rules for *.ts files
119
+ // Base rules — all effective rules for TS plus shared JS/TS rules
35
120
  {
36
121
  name: "eslint-config-setup/base",
122
+ ignores: ["**/*.{md,mdx}"],
37
123
  plugins: {
38
124
  "@cspell": cspellPlugin,
39
125
  "@stylistic": stylisticPlugin,
@@ -44,11 +130,8 @@ export default [
44
130
  "jsx-a11y": jsxA11yPlugin,
45
131
  "node": nodePlugin,
46
132
  "perfectionist": perfectionistPlugin,
47
- "react": eslintReactPlugin,
48
- "react-dom": eslintReactPlugin.configs.dom.plugins["@eslint-react/dom"],
49
- "react-hooks": reactHooksPlugin,
133
+ "react": reactCompatPlugin,
50
134
  "react-refresh": reactRefreshPlugin,
51
- "react-web-api": eslintReactPlugin.configs["web-api"].plugins["@eslint-react/web-api"],
52
135
  "react-you-might-not-need-an-effect": reactEffectPlugin,
53
136
  "regexp": regexpPlugin,
54
137
  "security": securityPlugin,
@@ -96,7 +179,7 @@ export default [
96
179
  "@typescript-eslint/ban-ts-comment": [
97
180
  "error",
98
181
  {
99
- "minimumDescriptionLength": 10
182
+ "ts-expect-error": "allow-with-description"
100
183
  }
101
184
  ],
102
185
  "@typescript-eslint/ban-tslint-comment": "error",
@@ -323,12 +406,7 @@ export default [
323
406
  "@typescript-eslint/no-dynamic-delete": "error",
324
407
  "@typescript-eslint/no-empty-function": "error",
325
408
  "@typescript-eslint/no-empty-object-type": "error",
326
- "@typescript-eslint/no-explicit-any": [
327
- "error",
328
- {
329
- "fixToUnknown": true
330
- }
331
- ],
409
+ "@typescript-eslint/no-explicit-any": "error",
332
410
  "@typescript-eslint/no-extra-non-null-assertion": "error",
333
411
  "@typescript-eslint/no-extraneous-class": "error",
334
412
  "@typescript-eslint/no-floating-promises": [
@@ -364,7 +442,12 @@ export default [
364
442
  ],
365
443
  "@typescript-eslint/no-meaningless-void-operator": "error",
366
444
  "@typescript-eslint/no-misused-new": "error",
367
- "@typescript-eslint/no-misused-promises": "error",
445
+ "@typescript-eslint/no-misused-promises": [
446
+ "error",
447
+ {
448
+ "checksVoidReturn": false
449
+ }
450
+ ],
368
451
  "@typescript-eslint/no-misused-spread": "error",
369
452
  "@typescript-eslint/no-mixed-enums": "error",
370
453
  "@typescript-eslint/no-namespace": "error",
@@ -512,7 +595,10 @@ export default [
512
595
  "de-morgan/no-negated-conjunction": "error",
513
596
  "de-morgan/no-negated-disjunction": "error",
514
597
  "default-case-last": "error",
515
- "eqeqeq": "error",
598
+ "eqeqeq": [
599
+ "error",
600
+ "smart"
601
+ ],
516
602
  "for-direction": "error",
517
603
  "grouped-accessor-pairs": [
518
604
  "error",
@@ -528,17 +614,35 @@ export default [
528
614
  "maxDepth": 3
529
615
  }
530
616
  ],
531
- "import/no-duplicates": [
617
+ "import/no-duplicates": "error",
618
+ "import/no-empty-named-blocks": "error",
619
+ "import/no-extraneous-dependencies": [
532
620
  "error",
533
621
  {
534
- "prefer-inline": true
622
+ "includeTypes": true
535
623
  }
536
624
  ],
537
- "import/no-empty-named-blocks": "error",
538
625
  "import/no-mutable-exports": "error",
539
626
  "import/no-named-as-default": "error",
540
627
  "import/no-named-as-default-member": "error",
628
+ "import/no-named-default": "error",
541
629
  "import/no-self-import": "error",
630
+ "import/no-unassigned-import": [
631
+ "error",
632
+ {
633
+ "allow": [
634
+ "@babel/polyfill",
635
+ "**/register",
636
+ "**/register.*",
637
+ "**/register/**",
638
+ "**/register/**.*",
639
+ "**/*.css",
640
+ "**/*.scss",
641
+ "**/*.sass",
642
+ "**/*.less"
643
+ ]
644
+ }
645
+ ],
542
646
  "import/no-useless-path-segments": "error",
543
647
  "jsdoc/check-access": "error",
544
648
  "jsdoc/check-alignment": "error",
@@ -627,7 +731,7 @@ export default [
627
731
  "max-lines-per-function": [
628
732
  "error",
629
733
  {
630
- "max": 50,
734
+ "max": 100,
631
735
  "skipBlankLines": true,
632
736
  "skipComments": true
633
737
  }
@@ -676,6 +780,7 @@ export default [
676
780
  "no-fallthrough": "error",
677
781
  "no-global-assign": "error",
678
782
  "no-implicit-coercion": "error",
783
+ "no-implicit-globals": "error",
679
784
  "no-irregular-whitespace": "error",
680
785
  "no-iterator": "error",
681
786
  "no-labels": "error",
@@ -711,7 +816,12 @@ export default [
711
816
  "no-script-url": "error",
712
817
  "no-self-assign": "error",
713
818
  "no-self-compare": "error",
714
- "no-sequences": "error",
819
+ "no-sequences": [
820
+ "error",
821
+ {
822
+ "allowInParentheses": false
823
+ }
824
+ ],
715
825
  "no-shadow-restricted-names": "error",
716
826
  "no-sparse-arrays": "error",
717
827
  "no-template-curly-in-string": "error",
@@ -726,13 +836,19 @@ export default [
726
836
  "no-useless-assignment": "error",
727
837
  "no-useless-call": "error",
728
838
  "no-useless-catch": "error",
729
- "no-useless-computed-key": "error",
839
+ "no-useless-computed-key": [
840
+ "error",
841
+ {
842
+ "enforceForClassMembers": true
843
+ }
844
+ ],
730
845
  "no-useless-concat": "error",
731
846
  "no-useless-escape": "error",
732
847
  "no-useless-rename": "error",
733
848
  "no-useless-return": "error",
734
849
  "no-var": "error",
735
850
  "no-warning-comments": "warn",
851
+ "node/handle-callback-err": "error",
736
852
  "node/hashbang": "error",
737
853
  "node/no-deprecated-api": "error",
738
854
  "node/no-exports-assign": "error",
@@ -761,10 +877,12 @@ export default [
761
877
  ],
762
878
  "node/prefer-promises/dns": "error",
763
879
  "node/prefer-promises/fs": "error",
880
+ "node/process-exit-as-throw": "error",
764
881
  "object-shorthand": [
765
882
  "error",
766
883
  "always",
767
884
  {
885
+ "avoidExplicitReturnArrows": true,
768
886
  "avoidQuotes": true
769
887
  }
770
888
  ],
@@ -799,14 +917,10 @@ export default [
799
917
  "allowNamedFunctions": true
800
918
  }
801
919
  ],
802
- "prefer-const": [
803
- "error",
804
- {
805
- "destructuring": "all"
806
- }
807
- ],
920
+ "prefer-const": "error",
808
921
  "prefer-exponentiation-operator": "error",
809
922
  "prefer-named-capture-group": "error",
923
+ "prefer-numeric-literals": "error",
810
924
  "prefer-object-has-own": "error",
811
925
  "prefer-object-spread": "error",
812
926
  "prefer-regex-literals": "error",
@@ -815,26 +929,12 @@ export default [
815
929
  "prefer-template": "error",
816
930
  "preserve-caught-error": "error",
817
931
  "radix": "error",
818
- "react-dom/no-dangerously-set-innerhtml": "warn",
819
- "react-dom/no-dangerously-set-innerhtml-with-children": "error",
820
- "react-dom/no-missing-button-type": "error",
821
- "react-dom/no-missing-iframe-sandbox": "error",
822
- "react-dom/no-string-style-prop": "error",
823
- "react-dom/no-unknown-property": "error",
824
- "react-dom/no-unsafe-target-blank": "error",
825
- "react-dom/no-void-elements-with-children": "error",
826
- "react-hooks/exhaustive-deps": "error",
827
- "react-hooks/rules-of-hooks": "error",
828
932
  "react-refresh/only-export-components": [
829
933
  "warn",
830
934
  {
831
935
  "allowConstantExport": true
832
936
  }
833
937
  ],
834
- "react-web-api/no-leaked-event-listener": "error",
835
- "react-web-api/no-leaked-interval": "error",
836
- "react-web-api/no-leaked-resize-observer": "error",
837
- "react-web-api/no-leaked-timeout": "error",
838
938
  "react-you-might-not-need-an-effect/no-adjust-state-on-prop-change": "warn",
839
939
  "react-you-might-not-need-an-effect/no-chain-state-updates": "error",
840
940
  "react-you-might-not-need-an-effect/no-derived-state": "error",
@@ -844,23 +944,87 @@ export default [
844
944
  "react-you-might-not-need-an-effect/no-pass-data-to-parent": "error",
845
945
  "react-you-might-not-need-an-effect/no-pass-live-state-to-parent": "error",
846
946
  "react-you-might-not-need-an-effect/no-reset-all-state-on-prop-change": "error",
947
+ "react/button-has-type": "error",
948
+ "react/component-hook-factories": "error",
949
+ "react/context-name": "warn",
950
+ "react/destructuring-assignment": "warn",
951
+ "react/error-boundaries": "error",
952
+ "react/exhaustive-deps": "warn",
953
+ "react/forward-ref-uses-ref": "error",
954
+ "react/function-definition": "error",
955
+ "react/hook-use-state": "warn",
956
+ "react/id-name": "warn",
957
+ "react/iframe-missing-sandbox": "error",
958
+ "react/jsx-key": "error",
959
+ "react/jsx-key-before-spread": "error",
960
+ "react/jsx-no-children-prop-with-children": "error",
847
961
  "react/jsx-no-comment-textnodes": "error",
848
- "react/jsx-shorthand-boolean": "error",
962
+ "react/jsx-no-constructed-context-values": "error",
963
+ "react/jsx-no-leaked-render": "error",
964
+ "react/jsx-no-leaked-semicolon": "warn",
965
+ "react/jsx-no-script-url": "warn",
966
+ "react/jsx-no-target-blank": "error",
967
+ "react/jsx-no-useless-fragment": "error",
849
968
  "react/no-access-state-in-setstate": "error",
850
969
  "react/no-array-index-key": "error",
970
+ "react/no-children-count": "warn",
971
+ "react/no-children-for-each": "warn",
972
+ "react/no-children-map": "warn",
973
+ "react/no-children-only": "warn",
851
974
  "react/no-children-prop": "error",
975
+ "react/no-children-to-array": "warn",
976
+ "react/no-class-component": "error",
977
+ "react/no-clone-element": "warn",
978
+ "react/no-component-will-mount": "error",
979
+ "react/no-component-will-receive-props": "error",
980
+ "react/no-component-will-update": "error",
852
981
  "react/no-context-provider": "error",
982
+ "react/no-create-ref": "error",
983
+ "react/no-danger": "warn",
984
+ "react/no-danger-with-children": "error",
985
+ "react/no-did-mount-set-state": "warn",
986
+ "react/no-did-update-set-state": "warn",
853
987
  "react/no-direct-mutation-state": "error",
854
988
  "react/no-duplicate-key": "error",
855
- "react/no-forward-ref": "error",
856
- "react/no-leaked-conditional-rendering": "error",
857
- "react/no-missing-key": "error",
858
- "react/no-nested-component-definitions": "error",
859
- "react/no-unstable-context-value": "error",
860
- "react/no-unstable-default-props": "error",
989
+ "react/no-find-dom-node": "error",
990
+ "react/no-flush-sync": "error",
991
+ "react/no-hydrate": "error",
992
+ "react/no-implicit-key": "error",
993
+ "react/no-leaked-event-listener": "error",
994
+ "react/no-leaked-interval": "error",
995
+ "react/no-leaked-resize-observer": "error",
996
+ "react/no-leaked-timeout": "error",
997
+ "react/no-misused-capture-owner-stack": "error",
998
+ "react/no-namespace": "error",
999
+ "react/no-nested-lazy-component-declarations": "error",
1000
+ "react/no-object-type-as-default-prop": "error",
1001
+ "react/no-redundant-should-component-update": "error",
1002
+ "react/no-render": "error",
1003
+ "react/no-render-return-value": "error",
1004
+ "react/no-unknown-property": "error",
1005
+ "react/no-unnecessary-use-callback": "warn",
1006
+ "react/no-unnecessary-use-memo": "warn",
1007
+ "react/no-unnecessary-use-prefix": "warn",
1008
+ "react/no-unsafe-component-will-mount": "warn",
1009
+ "react/no-unsafe-component-will-receive-props": "warn",
1010
+ "react/no-unsafe-component-will-update": "warn",
1011
+ "react/no-unsafe-iframe-sandbox": "warn",
1012
+ "react/no-unstable-nested-components": "error",
1013
+ "react/no-unused-class-component-members": "warn",
1014
+ "react/no-unused-props": "warn",
861
1015
  "react/no-unused-state": "error",
862
1016
  "react/no-use-context": "error",
863
- "react/no-useless-fragment": "error",
1017
+ "react/no-use-form-state": "error",
1018
+ "react/no-will-update-set-state": "warn",
1019
+ "react/purity": "warn",
1020
+ "react/ref-name": "warn",
1021
+ "react/rules-of-hooks": "error",
1022
+ "react/set-state-in-effect": "warn",
1023
+ "react/set-state-in-render": "error",
1024
+ "react/style-prop-object": "error",
1025
+ "react/unsupported-syntax": "error",
1026
+ "react/use-memo": "error",
1027
+ "react/void-dom-elements-no-children": "error",
864
1028
  "regexp/confusing-quantifier": "warn",
865
1029
  "regexp/control-character-escape": "error",
866
1030
  "regexp/match-any": "error",
@@ -1007,7 +1171,8 @@ export default [
1007
1171
  {
1008
1172
  "cases": {
1009
1173
  "camelCase": true,
1010
- "pascalCase": true
1174
+ "pascalCase": true,
1175
+ "kebabCase": true
1011
1176
  }
1012
1177
  }
1013
1178
  ],
@@ -1041,7 +1206,12 @@ export default [
1041
1206
  "unicorn/no-useless-promise-resolve-reject": "error",
1042
1207
  "unicorn/no-useless-spread": "error",
1043
1208
  "unicorn/no-useless-switch-case": "error",
1044
- "unicorn/no-useless-undefined": "error",
1209
+ "unicorn/no-useless-undefined": [
1210
+ "warn",
1211
+ {
1212
+ "checkArguments": false
1213
+ }
1214
+ ],
1045
1215
  "unicorn/no-zero-fractions": "error",
1046
1216
  "unicorn/numeric-separators-style": "error",
1047
1217
  "unicorn/prefer-array-find": "error",
@@ -1052,6 +1222,7 @@ export default [
1052
1222
  "unicorn/prefer-at": "error",
1053
1223
  "unicorn/prefer-date-now": "error",
1054
1224
  "unicorn/prefer-default-parameters": "error",
1225
+ "unicorn/prefer-dom-node-dataset": "error",
1055
1226
  "unicorn/prefer-export-from": [
1056
1227
  "error",
1057
1228
  {
@@ -1098,8 +1269,19 @@ export default [
1098
1269
  "unicorn/text-encoding-identifier-case": "error",
1099
1270
  "unicorn/throw-new-error": "error",
1100
1271
  "unused-imports/no-unused-imports": "error",
1101
- "use-isnan": "error",
1102
- "valid-typeof": "error",
1272
+ "use-isnan": [
1273
+ "error",
1274
+ {
1275
+ "enforceForIndexOf": true,
1276
+ "enforceForSwitchCase": true
1277
+ }
1278
+ ],
1279
+ "valid-typeof": [
1280
+ "error",
1281
+ {
1282
+ "requireStringLiterals": true
1283
+ }
1284
+ ],
1103
1285
  "yoda": "error"
1104
1286
  },
1105
1287
  },
@@ -1109,78 +1291,156 @@ export default [
1109
1291
  name: "eslint-config-setup/js-compat",
1110
1292
  files: ["**/*.{js,mjs,cjs}"],
1111
1293
  rules: {
1294
+ "@typescript-eslint/adjacent-overload-signatures": "off",
1295
+ "@typescript-eslint/array-type": "off",
1112
1296
  "@typescript-eslint/await-thenable": "off",
1297
+ "@typescript-eslint/ban-ts-comment": "off",
1298
+ "@typescript-eslint/ban-tslint-comment": "off",
1299
+ "@typescript-eslint/class-literal-property-style": "off",
1300
+ "@typescript-eslint/consistent-generic-constructors": "off",
1301
+ "@typescript-eslint/consistent-indexed-object-style": "off",
1113
1302
  "@typescript-eslint/consistent-return": "off",
1303
+ "@typescript-eslint/consistent-type-assertions": "off",
1304
+ "@typescript-eslint/consistent-type-definitions": "off",
1305
+ "@typescript-eslint/consistent-type-exports": "off",
1306
+ "@typescript-eslint/consistent-type-imports": "off",
1114
1307
  "@typescript-eslint/dot-notation": "off",
1308
+ "@typescript-eslint/explicit-function-return-type": "off",
1309
+ "@typescript-eslint/explicit-member-accessibility": "off",
1310
+ "@typescript-eslint/member-ordering": "off",
1311
+ "@typescript-eslint/method-signature-style": "off",
1312
+ "@typescript-eslint/naming-convention": "off",
1313
+ "@typescript-eslint/no-array-constructor": "off",
1115
1314
  "@typescript-eslint/no-array-delete": "off",
1116
1315
  "@typescript-eslint/no-base-to-string": "off",
1316
+ "@typescript-eslint/no-confusing-non-null-assertion": "off",
1117
1317
  "@typescript-eslint/no-confusing-void-expression": "off",
1118
1318
  "@typescript-eslint/no-deprecated": "off",
1319
+ "@typescript-eslint/no-duplicate-enum-values": "off",
1119
1320
  "@typescript-eslint/no-duplicate-type-constituents": "off",
1321
+ "@typescript-eslint/no-dynamic-delete": "off",
1322
+ "@typescript-eslint/no-empty-function": "off",
1323
+ "@typescript-eslint/no-empty-object-type": "off",
1324
+ "@typescript-eslint/no-explicit-any": "off",
1325
+ "@typescript-eslint/no-extra-non-null-assertion": "off",
1326
+ "@typescript-eslint/no-extraneous-class": "off",
1327
+ "@typescript-eslint/no-floating-promises": "off",
1120
1328
  "@typescript-eslint/no-for-in-array": "off",
1121
1329
  "@typescript-eslint/no-implied-eval": "off",
1330
+ "@typescript-eslint/no-import-type-side-effects": "off",
1331
+ "@typescript-eslint/no-inferrable-types": "off",
1332
+ "@typescript-eslint/no-invalid-void-type": "off",
1333
+ "@typescript-eslint/no-magic-numbers": "off",
1122
1334
  "@typescript-eslint/no-meaningless-void-operator": "off",
1335
+ "@typescript-eslint/no-misused-new": "off",
1123
1336
  "@typescript-eslint/no-misused-promises": "off",
1124
1337
  "@typescript-eslint/no-misused-spread": "off",
1125
1338
  "@typescript-eslint/no-mixed-enums": "off",
1339
+ "@typescript-eslint/no-namespace": "off",
1340
+ "@typescript-eslint/no-non-null-asserted-nullish-coalescing": "off",
1341
+ "@typescript-eslint/no-non-null-asserted-optional-chain": "off",
1342
+ "@typescript-eslint/no-non-null-assertion": "off",
1126
1343
  "@typescript-eslint/no-redundant-type-constituents": "off",
1344
+ "@typescript-eslint/no-require-imports": "off",
1345
+ "@typescript-eslint/no-shadow": "off",
1346
+ "@typescript-eslint/no-this-alias": "off",
1127
1347
  "@typescript-eslint/no-unnecessary-boolean-literal-compare": "off",
1128
1348
  "@typescript-eslint/no-unnecessary-condition": "off",
1349
+ "@typescript-eslint/no-unnecessary-parameter-property-assignment": "off",
1129
1350
  "@typescript-eslint/no-unnecessary-qualifier": "off",
1130
1351
  "@typescript-eslint/no-unnecessary-template-expression": "off",
1131
1352
  "@typescript-eslint/no-unnecessary-type-arguments": "off",
1132
1353
  "@typescript-eslint/no-unnecessary-type-assertion": "off",
1354
+ "@typescript-eslint/no-unnecessary-type-constraint": "off",
1133
1355
  "@typescript-eslint/no-unnecessary-type-conversion": "off",
1134
1356
  "@typescript-eslint/no-unnecessary-type-parameters": "off",
1135
1357
  "@typescript-eslint/no-unsafe-argument": "off",
1136
1358
  "@typescript-eslint/no-unsafe-assignment": "off",
1137
1359
  "@typescript-eslint/no-unsafe-call": "off",
1360
+ "@typescript-eslint/no-unsafe-declaration-merging": "off",
1138
1361
  "@typescript-eslint/no-unsafe-enum-comparison": "off",
1362
+ "@typescript-eslint/no-unsafe-function-type": "off",
1139
1363
  "@typescript-eslint/no-unsafe-member-access": "off",
1140
1364
  "@typescript-eslint/no-unsafe-return": "off",
1365
+ "@typescript-eslint/no-unsafe-type-assertion": "off",
1141
1366
  "@typescript-eslint/no-unsafe-unary-minus": "off",
1367
+ "@typescript-eslint/no-unused-expressions": "off",
1368
+ "@typescript-eslint/no-unused-vars": "off",
1369
+ "@typescript-eslint/no-useless-constructor": "off",
1142
1370
  "@typescript-eslint/no-useless-default-assignment": "off",
1371
+ "@typescript-eslint/no-useless-empty-export": "off",
1372
+ "@typescript-eslint/no-wrapper-object-types": "off",
1143
1373
  "@typescript-eslint/non-nullable-type-assertion-style": "off",
1144
1374
  "@typescript-eslint/only-throw-error": "off",
1375
+ "@typescript-eslint/prefer-as-const": "off",
1145
1376
  "@typescript-eslint/prefer-destructuring": "off",
1377
+ "@typescript-eslint/prefer-enum-initializers": "off",
1146
1378
  "@typescript-eslint/prefer-find": "off",
1379
+ "@typescript-eslint/prefer-for-of": "off",
1380
+ "@typescript-eslint/prefer-function-type": "off",
1147
1381
  "@typescript-eslint/prefer-includes": "off",
1382
+ "@typescript-eslint/prefer-literal-enum-member": "off",
1383
+ "@typescript-eslint/prefer-namespace-keyword": "off",
1148
1384
  "@typescript-eslint/prefer-nullish-coalescing": "off",
1149
1385
  "@typescript-eslint/prefer-optional-chain": "off",
1150
1386
  "@typescript-eslint/prefer-promise-reject-errors": "off",
1387
+ "@typescript-eslint/prefer-readonly": "off",
1151
1388
  "@typescript-eslint/prefer-readonly-parameter-types": "off",
1152
1389
  "@typescript-eslint/prefer-reduce-type-parameter": "off",
1153
1390
  "@typescript-eslint/prefer-regexp-exec": "off",
1154
1391
  "@typescript-eslint/prefer-return-this-type": "off",
1155
1392
  "@typescript-eslint/prefer-string-starts-ends-with": "off",
1393
+ "@typescript-eslint/promise-function-async": "off",
1156
1394
  "@typescript-eslint/related-getter-setter-pairs": "off",
1395
+ "@typescript-eslint/require-array-sort-compare": "off",
1157
1396
  "@typescript-eslint/require-await": "off",
1158
1397
  "@typescript-eslint/restrict-plus-operands": "off",
1159
1398
  "@typescript-eslint/restrict-template-expressions": "off",
1160
1399
  "@typescript-eslint/return-await": "off",
1161
1400
  "@typescript-eslint/strict-boolean-expressions": "off",
1162
1401
  "@typescript-eslint/strict-void-return": "off",
1402
+ "@typescript-eslint/switch-exhaustiveness-check": "off",
1403
+ "@typescript-eslint/triple-slash-reference": "off",
1163
1404
  "@typescript-eslint/unbound-method": "off",
1405
+ "@typescript-eslint/unified-signatures": "off",
1164
1406
  "@typescript-eslint/use-unknown-in-catch-callback-variable": "off",
1165
1407
  "constructor-super": "error",
1408
+ "dot-notation": "off",
1166
1409
  "getter-return": "error",
1410
+ "no-array-constructor": "off",
1167
1411
  "no-class-assign": "error",
1168
1412
  "no-const-assign": "error",
1169
1413
  "no-dupe-args": "error",
1170
1414
  "no-dupe-class-members": "error",
1171
1415
  "no-dupe-keys": "error",
1416
+ "no-empty-function": "off",
1172
1417
  "no-func-assign": "error",
1418
+ "no-implied-eval": "off",
1173
1419
  "no-import-assign": "error",
1174
1420
  "no-new-native-nonconstructor": "error",
1175
1421
  "no-new-symbol": "off",
1176
1422
  "no-obj-calls": "error",
1177
1423
  "no-redeclare": "error",
1424
+ "no-return-await": "off",
1178
1425
  "no-setter-return": "error",
1426
+ "no-shadow": "off",
1179
1427
  "no-this-before-super": "error",
1428
+ "no-throw-literal": "off",
1180
1429
  "no-undef": "error",
1181
1430
  "no-unreachable": "error",
1182
1431
  "no-unsafe-negation": "error",
1183
- "no-with": "error"
1432
+ "no-unused-expressions": "off",
1433
+ "no-unused-vars": "error",
1434
+ "no-useless-constructor": "off",
1435
+ "no-with": "error",
1436
+ "prefer-const": [
1437
+ "error",
1438
+ {
1439
+ "destructuring": "all"
1440
+ }
1441
+ ],
1442
+ "prefer-promise-reject-errors": "off",
1443
+ "require-await": "off"
1184
1444
  },
1185
1445
  },
1186
1446
 
@@ -1439,7 +1699,137 @@ export default [
1439
1699
  // Markdown/MDX code block linting
1440
1700
  {
1441
1701
  ...mdxPlugin.flatCodeBlocks,
1702
+ languageOptions: {
1703
+ ...mdxPlugin.flatCodeBlocks.languageOptions,
1704
+ parserOptions: {
1705
+ ...mdxPlugin.flatCodeBlocks.languageOptions?.parserOptions,
1706
+ projectService: false,
1707
+ },
1708
+ },
1442
1709
  rules: {
1710
+ ...{
1711
+ "@typescript-eslint/adjacent-overload-signatures": "off",
1712
+ "@typescript-eslint/array-type": "off",
1713
+ "@typescript-eslint/await-thenable": "off",
1714
+ "@typescript-eslint/ban-ts-comment": "off",
1715
+ "@typescript-eslint/ban-tslint-comment": "off",
1716
+ "@typescript-eslint/class-literal-property-style": "off",
1717
+ "@typescript-eslint/consistent-generic-constructors": "off",
1718
+ "@typescript-eslint/consistent-indexed-object-style": "off",
1719
+ "@typescript-eslint/consistent-type-assertions": "off",
1720
+ "@typescript-eslint/consistent-type-definitions": "off",
1721
+ "@typescript-eslint/consistent-type-exports": "off",
1722
+ "@typescript-eslint/consistent-type-imports": "off",
1723
+ "@typescript-eslint/dot-notation": "off",
1724
+ "@typescript-eslint/explicit-function-return-type": "off",
1725
+ "@typescript-eslint/explicit-member-accessibility": "off",
1726
+ "@typescript-eslint/member-ordering": "off",
1727
+ "@typescript-eslint/method-signature-style": "off",
1728
+ "@typescript-eslint/naming-convention": "off",
1729
+ "@typescript-eslint/no-array-constructor": "off",
1730
+ "@typescript-eslint/no-array-delete": "off",
1731
+ "@typescript-eslint/no-base-to-string": "off",
1732
+ "@typescript-eslint/no-confusing-non-null-assertion": "off",
1733
+ "@typescript-eslint/no-confusing-void-expression": "off",
1734
+ "@typescript-eslint/no-deprecated": "off",
1735
+ "@typescript-eslint/no-duplicate-enum-values": "off",
1736
+ "@typescript-eslint/no-duplicate-type-constituents": "off",
1737
+ "@typescript-eslint/no-dynamic-delete": "off",
1738
+ "@typescript-eslint/no-empty-function": "off",
1739
+ "@typescript-eslint/no-empty-object-type": "off",
1740
+ "@typescript-eslint/no-explicit-any": "off",
1741
+ "@typescript-eslint/no-extra-non-null-assertion": "off",
1742
+ "@typescript-eslint/no-extraneous-class": "off",
1743
+ "@typescript-eslint/no-floating-promises": "off",
1744
+ "@typescript-eslint/no-for-in-array": "off",
1745
+ "@typescript-eslint/no-implied-eval": "off",
1746
+ "@typescript-eslint/no-import-type-side-effects": "off",
1747
+ "@typescript-eslint/no-inferrable-types": "off",
1748
+ "@typescript-eslint/no-invalid-void-type": "off",
1749
+ "@typescript-eslint/no-magic-numbers": "off",
1750
+ "@typescript-eslint/no-meaningless-void-operator": "off",
1751
+ "@typescript-eslint/no-misused-new": "off",
1752
+ "@typescript-eslint/no-misused-spread": "off",
1753
+ "@typescript-eslint/no-mixed-enums": "off",
1754
+ "@typescript-eslint/no-namespace": "off",
1755
+ "@typescript-eslint/no-non-null-asserted-nullish-coalescing": "off",
1756
+ "@typescript-eslint/no-non-null-asserted-optional-chain": "off",
1757
+ "@typescript-eslint/no-non-null-assertion": "off",
1758
+ "@typescript-eslint/no-redundant-type-constituents": "off",
1759
+ "@typescript-eslint/no-require-imports": "off",
1760
+ "@typescript-eslint/no-shadow": "off",
1761
+ "@typescript-eslint/no-this-alias": "off",
1762
+ "@typescript-eslint/no-unnecessary-boolean-literal-compare": "off",
1763
+ "@typescript-eslint/no-unnecessary-condition": "off",
1764
+ "@typescript-eslint/no-unnecessary-parameter-property-assignment": "off",
1765
+ "@typescript-eslint/no-unnecessary-qualifier": "off",
1766
+ "@typescript-eslint/no-unnecessary-template-expression": "off",
1767
+ "@typescript-eslint/no-unnecessary-type-arguments": "off",
1768
+ "@typescript-eslint/no-unnecessary-type-assertion": "off",
1769
+ "@typescript-eslint/no-unnecessary-type-constraint": "off",
1770
+ "@typescript-eslint/no-unnecessary-type-conversion": "off",
1771
+ "@typescript-eslint/no-unnecessary-type-parameters": "off",
1772
+ "@typescript-eslint/no-unsafe-argument": "off",
1773
+ "@typescript-eslint/no-unsafe-assignment": "off",
1774
+ "@typescript-eslint/no-unsafe-call": "off",
1775
+ "@typescript-eslint/no-unsafe-declaration-merging": "off",
1776
+ "@typescript-eslint/no-unsafe-enum-comparison": "off",
1777
+ "@typescript-eslint/no-unsafe-function-type": "off",
1778
+ "@typescript-eslint/no-unsafe-member-access": "off",
1779
+ "@typescript-eslint/no-unsafe-return": "off",
1780
+ "@typescript-eslint/no-unsafe-type-assertion": "off",
1781
+ "@typescript-eslint/no-unsafe-unary-minus": "off",
1782
+ "@typescript-eslint/no-unused-expressions": "off",
1783
+ "@typescript-eslint/no-unused-vars": "off",
1784
+ "@typescript-eslint/no-useless-constructor": "off",
1785
+ "@typescript-eslint/no-useless-default-assignment": "off",
1786
+ "@typescript-eslint/no-useless-empty-export": "off",
1787
+ "@typescript-eslint/no-wrapper-object-types": "off",
1788
+ "@typescript-eslint/non-nullable-type-assertion-style": "off",
1789
+ "@typescript-eslint/only-throw-error": "off",
1790
+ "@typescript-eslint/prefer-as-const": "off",
1791
+ "@typescript-eslint/prefer-enum-initializers": "off",
1792
+ "@typescript-eslint/prefer-find": "off",
1793
+ "@typescript-eslint/prefer-for-of": "off",
1794
+ "@typescript-eslint/prefer-function-type": "off",
1795
+ "@typescript-eslint/prefer-includes": "off",
1796
+ "@typescript-eslint/prefer-literal-enum-member": "off",
1797
+ "@typescript-eslint/prefer-namespace-keyword": "off",
1798
+ "@typescript-eslint/prefer-nullish-coalescing": "off",
1799
+ "@typescript-eslint/prefer-optional-chain": "off",
1800
+ "@typescript-eslint/prefer-promise-reject-errors": "off",
1801
+ "@typescript-eslint/prefer-readonly": "off",
1802
+ "@typescript-eslint/prefer-reduce-type-parameter": "off",
1803
+ "@typescript-eslint/prefer-regexp-exec": "off",
1804
+ "@typescript-eslint/prefer-return-this-type": "off",
1805
+ "@typescript-eslint/prefer-string-starts-ends-with": "off",
1806
+ "@typescript-eslint/promise-function-async": "off",
1807
+ "@typescript-eslint/related-getter-setter-pairs": "off",
1808
+ "@typescript-eslint/require-array-sort-compare": "off",
1809
+ "@typescript-eslint/require-await": "off",
1810
+ "@typescript-eslint/restrict-plus-operands": "off",
1811
+ "@typescript-eslint/restrict-template-expressions": "off",
1812
+ "@typescript-eslint/return-await": "off",
1813
+ "@typescript-eslint/strict-boolean-expressions": "off",
1814
+ "@typescript-eslint/strict-void-return": "off",
1815
+ "@typescript-eslint/switch-exhaustiveness-check": "off",
1816
+ "@typescript-eslint/triple-slash-reference": "off",
1817
+ "@typescript-eslint/unbound-method": "off",
1818
+ "@typescript-eslint/unified-signatures": "off",
1819
+ "@typescript-eslint/use-unknown-in-catch-callback-variable": "off",
1820
+ "dot-notation": "off",
1821
+ "no-array-constructor": "off",
1822
+ "no-empty-function": "off",
1823
+ "no-implied-eval": "off",
1824
+ "no-return-await": "off",
1825
+ "no-shadow": "off",
1826
+ "no-throw-literal": "off",
1827
+ "no-useless-constructor": "off",
1828
+ "prefer-promise-reject-errors": "off",
1829
+ "require-await": "off",
1830
+ "strict": "off",
1831
+ "unicode-bom": "off"
1832
+ },
1443
1833
  ...mdxPlugin.flatCodeBlocks.rules,
1444
1834
  "eol-last": "off",
1445
1835
  "no-undef": "off",