@isentinel/eslint-config 6.3.0 → 6.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.
package/dist/oxlint.mjs CHANGED
@@ -132,14 +132,19 @@ const jsPluginRuleNames = /* @__PURE__ */ new Set([
132
132
  "eslint-plugin/test-case-shorthand-strings",
133
133
  "eslint-plugin/unique-test-case-names",
134
134
  "flawless/arrow-return-style",
135
+ "flawless/cognitive-complexity",
135
136
  "flawless/jsx-shorthand-boolean",
136
137
  "flawless/jsx-shorthand-fragment",
138
+ "flawless/max-comment-length",
137
139
  "flawless/max-lines-per-function",
138
140
  "flawless/naming-convention",
139
141
  "flawless/no-conditional-empty-object-spread",
140
142
  "flawless/no-conditional-in-test",
143
+ "flawless/no-em-dash",
141
144
  "flawless/no-export-default-arrow",
142
145
  "flawless/no-floating-point-equality",
146
+ "flawless/no-ignored-return",
147
+ "flawless/no-incompatible-assertion-types",
143
148
  "flawless/no-known-value-widening",
144
149
  "flawless/no-materialized-filter-map",
145
150
  "flawless/no-object-parameters",
@@ -150,8 +155,10 @@ const jsPluginRuleNames = /* @__PURE__ */ new Set([
150
155
  "flawless/no-shape-in-symbol-names",
151
156
  "flawless/no-shared-mocks",
152
157
  "flawless/no-shared-test-state",
158
+ "flawless/no-trivial-functions",
153
159
  "flawless/no-unknown-parameters",
154
160
  "flawless/no-unknown-returns",
161
+ "flawless/no-unnecessary-prop-alias",
155
162
  "flawless/no-unnecessary-use-callback",
156
163
  "flawless/no-unnecessary-use-memo",
157
164
  "flawless/no-unsafe-dictionary-type",
@@ -167,6 +174,7 @@ const jsPluginRuleNames = /* @__PURE__ */ new Set([
167
174
  "flawless/react-namespace",
168
175
  "flawless/toml-sort-keys",
169
176
  "flawless/yaml-block-key-blank-lines",
177
+ "flawless/yaml-sort-sequence-by-key",
170
178
  "for-direction",
171
179
  "func-call-spacing",
172
180
  "func-name-matching",
@@ -304,6 +312,7 @@ const jsPluginRuleNames = /* @__PURE__ */ new Set([
304
312
  "jsdoc/no-restricted-syntax",
305
313
  "jsdoc/no-types",
306
314
  "jsdoc/no-undefined-types",
315
+ "jsdoc/no-unnecessary-type-assertion",
307
316
  "jsdoc/normalize-see-links",
308
317
  "jsdoc/prefer-import-tag",
309
318
  "jsdoc/reject-any-type",
@@ -343,6 +352,7 @@ const jsPluginRuleNames = /* @__PURE__ */ new Set([
343
352
  "jsdoc/sort-tags",
344
353
  "jsdoc/tag-lines",
345
354
  "jsdoc/text-escaping",
355
+ "jsdoc/ts-ban-ts-comment",
346
356
  "jsdoc/ts-method-signature-style",
347
357
  "jsdoc/ts-no-empty-object-type",
348
358
  "jsdoc/ts-no-unnecessary-template-expression",
@@ -596,6 +606,7 @@ const jsPluginRuleNames = /* @__PURE__ */ new Set([
596
606
  "perfectionist/sort-array-includes",
597
607
  "perfectionist/sort-arrays",
598
608
  "perfectionist/sort-classes",
609
+ "perfectionist/sort-constructor-parameters",
599
610
  "perfectionist/sort-decorators",
600
611
  "perfectionist/sort-enums",
601
612
  "perfectionist/sort-export-attributes",
@@ -757,6 +768,7 @@ const jsPluginRuleNames = /* @__PURE__ */ new Set([
757
768
  "small-rules/ban-react-fc",
758
769
  "small-rules/ban-types",
759
770
  "small-rules/consistent-compound-words",
771
+ "small-rules/curly",
760
772
  "small-rules/directive-disable-enable-pair",
761
773
  "small-rules/directive-no-aggregating-enable",
762
774
  "small-rules/directive-no-duplicate-disable",
@@ -768,53 +780,89 @@ const jsPluginRuleNames = /* @__PURE__ */ new Set([
768
780
  "small-rules/enforce-ianitor-check-type",
769
781
  "small-rules/isolated-functions",
770
782
  "small-rules/memoized-effect-dependencies",
783
+ "small-rules/no-adjust-state-on-prop-change",
771
784
  "small-rules/no-array-constructor-elements",
772
785
  "small-rules/no-array-constructor-index-assignment",
773
786
  "small-rules/no-array-size-assignment",
774
787
  "small-rules/no-async-constructor",
775
788
  "small-rules/no-async-in-system",
776
789
  "small-rules/no-cascading-set-state",
790
+ "small-rules/no-chain-state-updates",
791
+ "small-rules/no-chained-type-assertions",
792
+ "small-rules/no-cliffy-action-wrapper",
777
793
  "small-rules/no-color3-constructor",
778
794
  "small-rules/no-commented-code",
795
+ "small-rules/no-conditional-empty-object-spread",
779
796
  "small-rules/no-constant-condition-with-break",
780
797
  "small-rules/no-dead-store",
798
+ "small-rules/no-derived-state",
799
+ "small-rules/no-discarded-rejection",
781
800
  "small-rules/no-error",
801
+ "small-rules/no-event-handler",
782
802
  "small-rules/no-events-in-events-callback",
803
+ "small-rules/no-external-store-subscription",
783
804
  "small-rules/no-filter-map-chain",
784
805
  "small-rules/no-floating-point-equality",
785
806
  "small-rules/no-giant-component",
786
807
  "small-rules/no-god-components",
808
+ "small-rules/no-has-before-remove-in-jecs",
787
809
  "small-rules/no-ianitor-in-function-body",
788
810
  "small-rules/no-ianitor-success-access",
789
811
  "small-rules/no-identity-map",
790
812
  "small-rules/no-increment-decrement",
813
+ "small-rules/no-initialize-state",
791
814
  "small-rules/no-inline-property-on-memo-component",
815
+ "small-rules/no-inline-signature-types",
792
816
  "small-rules/no-instance-methods-without-this",
817
+ "small-rules/no-jsx-spread-child",
818
+ "small-rules/no-known-value-widening",
793
819
  "small-rules/no-loop-iterable-mutation",
820
+ "small-rules/no-module-mocking",
821
+ "small-rules/no-multiple-cliffy-commands",
794
822
  "small-rules/no-native-properties-spread",
823
+ "small-rules/no-nested-hook-calls",
795
824
  "small-rules/no-new-instance-in-use-memo",
825
+ "small-rules/no-object-parameters",
826
+ "small-rules/no-pass-data-to-parent",
827
+ "small-rules/no-pass-live-state-to-parent",
796
828
  "small-rules/no-print",
829
+ "small-rules/no-real-temporary-directory",
797
830
  "small-rules/no-recursive",
831
+ "small-rules/no-reduce-accumulator-copy",
798
832
  "small-rules/no-redundant-aspect-ratio-constraint",
833
+ "small-rules/no-reflect-apply",
834
+ "small-rules/no-reflect-get",
799
835
  "small-rules/no-render-helper-functions",
836
+ "small-rules/no-reset-all-state-on-prop-change",
800
837
  "small-rules/no-restricted-property-assignment",
838
+ "small-rules/no-runtime-in-type-files",
839
+ "small-rules/no-runtime-typeof",
840
+ "small-rules/no-shape-in-symbol-names",
801
841
  "small-rules/no-spec-file-extension",
802
842
  "small-rules/no-static-react-create-element",
803
843
  "small-rules/no-table-create-map",
804
844
  "small-rules/no-task-wait",
845
+ "small-rules/no-test-timeout",
805
846
  "small-rules/no-trivial-assertions",
806
847
  "small-rules/no-underscore-react-props",
848
+ "small-rules/no-unknown-parameters",
849
+ "small-rules/no-unknown-returns",
850
+ "small-rules/no-unknown-type-aliases",
851
+ "small-rules/no-unsafe-dictionary-type",
852
+ "small-rules/no-unsupported-syntax",
807
853
  "small-rules/no-unused-imports",
808
854
  "small-rules/no-unused-use-memo",
809
855
  "small-rules/no-use-memo-simple-expression",
810
856
  "small-rules/no-use-of-empty-return-value",
811
857
  "small-rules/no-useless-constants",
812
858
  "small-rules/no-useless-default",
859
+ "small-rules/no-useless-empty-string-comparison",
813
860
  "small-rules/no-useless-use-effect",
814
861
  "small-rules/no-useless-use-memo",
815
862
  "small-rules/no-useless-use-spring",
816
863
  "small-rules/no-variadic-spread",
817
864
  "small-rules/no-warn",
865
+ "small-rules/no-widen-then-assert",
818
866
  "small-rules/only-type-imports",
819
867
  "small-rules/prefer-class-properties",
820
868
  "small-rules/prefer-constant-dispatch",
@@ -827,12 +875,15 @@ const jsPluginRuleNames = /* @__PURE__ */ new Set([
827
875
  "small-rules/prefer-idiv",
828
876
  "small-rules/prefer-local-portal-component",
829
877
  "small-rules/prefer-math-min-max",
878
+ "small-rules/prefer-membership-filter-in-jecs",
830
879
  "small-rules/prefer-modding-inspect",
831
880
  "small-rules/prefer-module-scope-constants",
881
+ "small-rules/prefer-native-collection-copy",
882
+ "small-rules/prefer-optional-parameter",
832
883
  "small-rules/prefer-padding-components",
833
884
  "small-rules/prefer-pascal-case-enums",
834
885
  "small-rules/prefer-sequence-overloads",
835
- "small-rules/prefer-single-world-query",
886
+ "small-rules/prefer-single-world-query-in-jecs",
836
887
  "small-rules/prefer-singular-enums",
837
888
  "small-rules/prefer-ternary-conditional-rendering",
838
889
  "small-rules/prefer-udim2-shorthand",
@@ -845,10 +896,14 @@ const jsPluginRuleNames = /* @__PURE__ */ new Set([
845
896
  "small-rules/require-paired-calls",
846
897
  "small-rules/require-react-component-keys",
847
898
  "small-rules/require-react-display-names",
899
+ "small-rules/require-readable-spacing",
900
+ "small-rules/require-safety-comment-for-type-assertion",
848
901
  "small-rules/require-switch-case-braces",
849
902
  "small-rules/require-throw-error-capture",
903
+ "small-rules/require-tsx-for-hooks",
850
904
  "small-rules/require-unicode-regex",
851
905
  "small-rules/rerender-memo-with-default-value",
906
+ "small-rules/starts-with-verb",
852
907
  "small-rules/strict-component-boundaries",
853
908
  "small-rules/use-exhaustive-dependencies",
854
909
  "small-rules/use-hook-at-top-level",
@@ -1847,6 +1902,8 @@ const jsPluginRuleNames = /* @__PURE__ */ new Set([
1847
1902
  const typeAwareJsPluginRuleNames = /* @__PURE__ */ new Set([
1848
1903
  "eslint-plugin/no-property-in-node",
1849
1904
  "flawless/naming-convention",
1905
+ "flawless/no-ignored-return",
1906
+ "flawless/no-incompatible-assertion-types",
1850
1907
  "flawless/no-materialized-filter-map",
1851
1908
  "flawless/no-redundant-type-annotation",
1852
1909
  "flawless/no-reflect-set",
@@ -2091,13 +2148,18 @@ const effectivePresetRuleNames = /* @__PURE__ */ new Set([
2091
2148
  "eslint-plugin/test-case-shorthand-strings",
2092
2149
  "eslint-plugin/unique-test-case-names",
2093
2150
  "flawless/arrow-return-style",
2151
+ "flawless/cognitive-complexity",
2094
2152
  "flawless/jsx-shorthand-boolean",
2095
2153
  "flawless/jsx-shorthand-fragment",
2154
+ "flawless/max-comment-length",
2096
2155
  "flawless/max-lines-per-function",
2097
2156
  "flawless/no-conditional-empty-object-spread",
2098
2157
  "flawless/no-conditional-in-test",
2158
+ "flawless/no-em-dash",
2099
2159
  "flawless/no-export-default-arrow",
2100
2160
  "flawless/no-floating-point-equality",
2161
+ "flawless/no-ignored-return",
2162
+ "flawless/no-incompatible-assertion-types",
2101
2163
  "flawless/no-known-value-widening",
2102
2164
  "flawless/no-materialized-filter-map",
2103
2165
  "flawless/no-object-parameters",
@@ -2106,7 +2168,10 @@ const effectivePresetRuleNames = /* @__PURE__ */ new Set([
2106
2168
  "flawless/no-reflect-set",
2107
2169
  "flawless/no-shape-in-symbol-names",
2108
2170
  "flawless/no-shared-mocks",
2171
+ "flawless/no-trivial-functions",
2172
+ "flawless/no-unknown-parameters",
2109
2173
  "flawless/no-unknown-returns",
2174
+ "flawless/no-unnecessary-prop-alias",
2110
2175
  "flawless/no-unnecessary-use-callback",
2111
2176
  "flawless/no-unnecessary-use-memo",
2112
2177
  "flawless/no-unsafe-dictionary-type",
@@ -2476,7 +2541,6 @@ const effectivePresetRuleNames = /* @__PURE__ */ new Set([
2476
2541
  "small-rules/require-async-suffix",
2477
2542
  "small-rules/strict-component-boundaries",
2478
2543
  "sonar/bool-param-default",
2479
- "sonar/cognitive-complexity",
2480
2544
  "sonar/constructor-for-side-effects",
2481
2545
  "sonar/destructuring-assignment-syntax",
2482
2546
  "sonar/elseif-without-else",
@@ -2493,13 +2557,10 @@ const effectivePresetRuleNames = /* @__PURE__ */ new Set([
2493
2557
  "sonar/no-duplicated-branches",
2494
2558
  "sonar/no-element-overwrite",
2495
2559
  "sonar/no-empty-collection",
2496
- "sonar/no-floating-point-equality",
2497
2560
  "sonar/no-gratuitous-expressions",
2498
2561
  "sonar/no-identical-conditions",
2499
2562
  "sonar/no-identical-expressions",
2500
2563
  "sonar/no-identical-functions",
2501
- "sonar/no-ignored-return",
2502
- "sonar/no-incompatible-assertion-types",
2503
2564
  "sonar/no-inverted-boolean-check",
2504
2565
  "sonar/no-mixed-completion-style",
2505
2566
  "sonar/no-nested-conditional",
@@ -2914,14 +2975,19 @@ const enabledPresetRuleNames = /* @__PURE__ */ new Set([
2914
2975
  "eslint-plugin/test-case-shorthand-strings",
2915
2976
  "eslint-plugin/unique-test-case-names",
2916
2977
  "flawless/arrow-return-style",
2978
+ "flawless/cognitive-complexity",
2917
2979
  "flawless/jsx-shorthand-boolean",
2918
2980
  "flawless/jsx-shorthand-fragment",
2981
+ "flawless/max-comment-length",
2919
2982
  "flawless/max-lines-per-function",
2920
2983
  "flawless/naming-convention",
2921
2984
  "flawless/no-conditional-empty-object-spread",
2922
2985
  "flawless/no-conditional-in-test",
2986
+ "flawless/no-em-dash",
2923
2987
  "flawless/no-export-default-arrow",
2924
2988
  "flawless/no-floating-point-equality",
2989
+ "flawless/no-ignored-return",
2990
+ "flawless/no-incompatible-assertion-types",
2925
2991
  "flawless/no-known-value-widening",
2926
2992
  "flawless/no-materialized-filter-map",
2927
2993
  "flawless/no-object-parameters",
@@ -2931,7 +2997,10 @@ const enabledPresetRuleNames = /* @__PURE__ */ new Set([
2931
2997
  "flawless/no-reflect-set",
2932
2998
  "flawless/no-shape-in-symbol-names",
2933
2999
  "flawless/no-shared-mocks",
3000
+ "flawless/no-trivial-functions",
3001
+ "flawless/no-unknown-parameters",
2934
3002
  "flawless/no-unknown-returns",
3003
+ "flawless/no-unnecessary-prop-alias",
2935
3004
  "flawless/no-unnecessary-use-callback",
2936
3005
  "flawless/no-unnecessary-use-memo",
2937
3006
  "flawless/no-unsafe-dictionary-type",
@@ -3393,7 +3462,6 @@ const enabledPresetRuleNames = /* @__PURE__ */ new Set([
3393
3462
  "small-rules/require-async-suffix",
3394
3463
  "small-rules/strict-component-boundaries",
3395
3464
  "sonar/bool-param-default",
3396
- "sonar/cognitive-complexity",
3397
3465
  "sonar/constructor-for-side-effects",
3398
3466
  "sonar/destructuring-assignment-syntax",
3399
3467
  "sonar/file-name-differ-from-class",
@@ -3406,12 +3474,9 @@ const enabledPresetRuleNames = /* @__PURE__ */ new Set([
3406
3474
  "sonar/no-duplicated-branches",
3407
3475
  "sonar/no-element-overwrite",
3408
3476
  "sonar/no-empty-collection",
3409
- "sonar/no-floating-point-equality",
3410
3477
  "sonar/no-identical-conditions",
3411
3478
  "sonar/no-identical-expressions",
3412
3479
  "sonar/no-identical-functions",
3413
- "sonar/no-ignored-return",
3414
- "sonar/no-incompatible-assertion-types",
3415
3480
  "sonar/no-inverted-boolean-check",
3416
3481
  "sonar/no-mixed-completion-style",
3417
3482
  "sonar/no-nested-conditional",
@@ -3469,6 +3534,7 @@ const enabledPresetRuleNames = /* @__PURE__ */ new Set([
3469
3534
  "style/key-spacing",
3470
3535
  "style/keyword-spacing",
3471
3536
  "style/lines-between-class-members",
3537
+ "style/max-len",
3472
3538
  "style/max-statements-per-line",
3473
3539
  "style/member-delimiter-style",
3474
3540
  "style/multiline-comment-style",
@@ -4248,16 +4314,24 @@ const oxlintNativeRuleNames = /* @__PURE__ */ new Set([
4248
4314
  "react-perf/jsx-no-new-function-as-prop",
4249
4315
  "react-perf/jsx-no-new-object-as-prop",
4250
4316
  "react/button-has-type",
4317
+ "react/capitalized-calls",
4251
4318
  "react/checked-requires-onchange-or-readonly",
4252
4319
  "react/display-name",
4320
+ "react/error-boundaries",
4253
4321
  "react/exhaustive-deps",
4322
+ "react/exhaustive-effect-dependencies",
4254
4323
  "react/forbid-component-props",
4255
4324
  "react/forbid-dom-props",
4256
4325
  "react/forbid-elements",
4257
4326
  "react/forward-ref-uses-ref",
4258
4327
  "react/function-component-definition",
4328
+ "react/globals",
4259
4329
  "react/hook-use-state",
4330
+ "react/hooks",
4260
4331
  "react/iframe-missing-sandbox",
4332
+ "react/immutability",
4333
+ "react/incompatible-library",
4334
+ "react/invariant",
4261
4335
  "react/jsx-boolean-value",
4262
4336
  "react/jsx-curly-brace-presence",
4263
4337
  "react/jsx-filename-extension",
@@ -4276,11 +4350,13 @@ const oxlintNativeRuleNames = /* @__PURE__ */ new Set([
4276
4350
  "react/jsx-pascal-case",
4277
4351
  "react/jsx-props-no-spread-multi",
4278
4352
  "react/jsx-props-no-spreading",
4353
+ "react/memo-dependencies",
4279
4354
  "react/no-array-index-key",
4280
4355
  "react/no-children-prop",
4281
4356
  "react/no-clone-element",
4282
4357
  "react/no-danger",
4283
4358
  "react/no-danger-with-children",
4359
+ "react/no-deriving-state-in-effects",
4284
4360
  "react/no-did-mount-set-state",
4285
4361
  "react/no-did-update-set-state",
4286
4362
  "react/no-direct-mutation-state",
@@ -4303,14 +4379,25 @@ const oxlintNativeRuleNames = /* @__PURE__ */ new Set([
4303
4379
  "react/only-export-components",
4304
4380
  "react/prefer-es6-class",
4305
4381
  "react/prefer-function-component",
4306
- "react/react-compiler",
4382
+ "react/preserve-manual-memoization",
4383
+ "react/purity",
4307
4384
  "react/react-in-jsx-scope",
4385
+ "react/refs",
4308
4386
  "react/require-render-return",
4387
+ "react/rule-suppression",
4309
4388
  "react/rules-of-hooks",
4310
4389
  "react/self-closing-comp",
4390
+ "react/set-state-in-effect",
4391
+ "react/set-state-in-render",
4311
4392
  "react/state-in-constructor",
4393
+ "react/static-components",
4312
4394
  "react/style-prop-object",
4395
+ "react/syntax",
4396
+ "react/todo",
4397
+ "react/unsupported-syntax",
4398
+ "react/use-memo",
4313
4399
  "react/void-dom-elements-no-children",
4400
+ "react/void-use-memo",
4314
4401
  "require-await",
4315
4402
  "require-unicode-regexp",
4316
4403
  "require-yield",
@@ -4352,6 +4439,7 @@ const oxlintNativeRuleNames = /* @__PURE__ */ new Set([
4352
4439
  "typescript/no-extraneous-class",
4353
4440
  "typescript/no-floating-promises",
4354
4441
  "typescript/no-for-in-array",
4442
+ "typescript/no-generated-empty-object-type",
4355
4443
  "typescript/no-implied-eval",
4356
4444
  "typescript/no-import-type-side-effects",
4357
4445
  "typescript/no-inferrable-types",
@@ -4383,6 +4471,7 @@ const oxlintNativeRuleNames = /* @__PURE__ */ new Set([
4383
4471
  "typescript/no-unsafe-assignment",
4384
4472
  "typescript/no-unsafe-call",
4385
4473
  "typescript/no-unsafe-declaration-merging",
4474
+ "typescript/no-unsafe-enum-assignment",
4386
4475
  "typescript/no-unsafe-enum-comparison",
4387
4476
  "typescript/no-unsafe-function-type",
4388
4477
  "typescript/no-unsafe-member-access",
@@ -4704,6 +4793,7 @@ const typeAwareNativeOxlintRuleNames = /* @__PURE__ */ new Set([
4704
4793
  "typescript/no-duplicate-type-constituents",
4705
4794
  "typescript/no-floating-promises",
4706
4795
  "typescript/no-for-in-array",
4796
+ "typescript/no-generated-empty-object-type",
4707
4797
  "typescript/no-implied-eval",
4708
4798
  "typescript/no-meaningless-void-operator",
4709
4799
  "typescript/no-misused-promises",
@@ -4721,6 +4811,7 @@ const typeAwareNativeOxlintRuleNames = /* @__PURE__ */ new Set([
4721
4811
  "typescript/no-unsafe-argument",
4722
4812
  "typescript/no-unsafe-assignment",
4723
4813
  "typescript/no-unsafe-call",
4814
+ "typescript/no-unsafe-enum-assignment",
4724
4815
  "typescript/no-unsafe-enum-comparison",
4725
4816
  "typescript/no-unsafe-member-access",
4726
4817
  "typescript/no-unsafe-return",
@@ -4832,6 +4923,8 @@ const optionallyTypeAwareRules = /* @__PURE__ */ new Set([
4832
4923
  */
4833
4924
  const typeAwareJsPluginRules = /* @__PURE__ */ new Set([
4834
4925
  "eslint-plugin/no-property-in-node",
4926
+ "flawless/no-ignored-return",
4927
+ "flawless/no-incompatible-assertion-types",
4835
4928
  "jest/no-error-equal",
4836
4929
  "jest/no-unnecessary-assertion",
4837
4930
  "jest/unbound-method",
@@ -4841,12 +4934,9 @@ const typeAwareJsPluginRules = /* @__PURE__ */ new Set([
4841
4934
  "react/no-implicit-ref",
4842
4935
  "react/no-leaked-conditional-rendering",
4843
4936
  "react/no-unused-props",
4844
- "sonar/no-ignored-return",
4845
- "sonar/no-incompatible-assertion-types",
4846
4937
  "sonar/no-redundant-optional",
4847
4938
  "sonar/no-try-promise",
4848
4939
  "sonar/prefer-immediate-return",
4849
- "ts/prefer-destructuring",
4850
4940
  "unicorn/no-non-function-verb-prefix"
4851
4941
  ]);
4852
4942
  const ESLINT_ONLY = "eslint-only";
@@ -4914,7 +5004,8 @@ const TS_EXTENSION_TO_CORE = /* @__PURE__ */ new Set([
4914
5004
  "no-shadow",
4915
5005
  "no-unused-expressions",
4916
5006
  "no-unused-private-class-members",
4917
- "no-useless-constructor"
5007
+ "no-useless-constructor",
5008
+ "prefer-destructuring"
4918
5009
  ]);
4919
5010
  /**
4920
5011
  * Unicorn rules renamed upstream but still exposed under the old Oxlint name.
@@ -4981,17 +5072,16 @@ function jsPluginAdapterFor(rule) {
4981
5072
  const staysInEslint = {
4982
5073
  "e18e/* (optionally type-aware)": "Four e18e rules (prefer-array-at, prefer-array-to-reversed, prefer-array-to-sorted, prefer-spread-syntax) run without type information but detect more with it, so they stay in ESLint (see optionallyTypeAwareRules); the rest run in oxlint as a jsPlugin",
4983
5074
  "eslint-comments/*": "Lints eslint-disable directives, which only exist in ESLint-linted code; oxlint-comments covers oxlint directives",
4984
- "flawless/naming-convention": "Type-aware custom rule; oxlint jsPlugins have no type information. The syntax-only flawless rules (arrow-return-style, max-lines-per-function, no-conditional-in-test, no-export-default-arrow, padding-after-expect-assertions, prefer-ending-with-an-expect, prefer-expect-assertions-count, prefer-parameter-destructuring, the react jsx-shorthand-*, purity, no-unnecessary-use-*, prefer-destructuring-assignment) run in oxlint. flawless/no-redundant-tsconfig-options and every flawless/toml-* and flawless/yaml-* rule lint non-JS files and stay in ESLint",
5075
+ "flawless/naming-convention": "Type-aware custom rule; oxlint jsPlugins have no type information. The syntax-only flawless rules (arrow-return-style, cognitive-complexity, max-comment-length, max-lines-per-function, no-em-dash, no-trivial-functions, no-unknown-parameters, no-unnecessary-prop-alias, no-conditional-in-test, no-export-default-arrow, padding-after-expect-assertions, prefer-ending-with-an-expect, prefer-expect-assertions-count, prefer-parameter-destructuring, the react jsx-shorthand-*, purity, no-unnecessary-use-*, prefer-destructuring-assignment) run in oxlint. flawless/no-redundant-tsconfig-options and every flawless/toml-* and flawless/yaml-* rule lint non-JS files and stay in ESLint",
4985
5076
  "flawless/prefer-read-only-props": "Type-aware custom rule; oxlint jsPlugins have no type information",
4986
5077
  "format-lua/*": "Oxlint cannot lint Lua files",
4987
5078
  "jest/* (type-aware)": "Four type-aware jest rules stay in ESLint (see typeAwareJsPluginRules); the rest run in oxlint via eslint-plugin-jest as a jsPlugin (renamed jest-js, since oxlint reserves the native jest prefix), which honors settings.jest.globalPackage = @rbxts/jest-globals (the NATIVE oxlint jest plugin does not, https://github.com/oxc-project/oxc/issues/23290)",
4988
- "jsdoc/require-param": "Oxlint's native port reports nested functions inside an unexported documented function (https://github.com/oxc-project/oxc/issues/27470)",
4989
5079
  "jsonc/yaml/toml/markdown/package-json/pnpm/sort-*": "Oxlint only lints JS/TS files; JSON, YAML, TOML and Markdown stay in ESLint",
4990
5080
  "react/* (type-aware)": "The @eslint-react type-aware rules (no-implicit-children/key/ref, no-leaked-conditional-rendering, no-unused-props) need type information but do NOT declare requiresTypeChecking, so the metadata-based parity test cannot catch them; they are excluded manually and stay in ESLint",
4991
5081
  "roblox/* (type-aware)": "Type-aware custom rules (lua-truthiness etc.); oxlint jsPlugins have no type information",
4992
5082
  "sentinel/explicit-size-check": "Type-aware custom rule; oxlint jsPlugins have no type information",
4993
5083
  "ts/no-shadow": "Oxlint's native port does not check members of declare namespace / declare module blocks in .d.ts files (https://github.com/oxc-project/oxc/issues/27469)",
4994
- "type-aware jsPlugin rules": "Rules whose meta.docs.requiresTypeChecking is true crash or silently no-op under oxlint's jsPlugin runtime (no type information): sonar/no-ignored-return, sonar/no-incompatible-assertion-types, sonar/no-redundant-optional, sonar/no-try-promise, sonar/prefer-immediate-return, unicorn/no-non-function-verb-prefix, eslint-plugin/no-property-in-node, jest/no-error-equal, jest/no-unnecessary-assertion, jest/unbound-method, jest/valid-expect-with-promise, ts/prefer-destructuring (also has no native oxlint port)",
5084
+ "type-aware jsPlugin rules": "Rules whose meta.docs.requiresTypeChecking is true crash or silently no-op under oxlint's jsPlugin runtime (no type information): flawless/no-ignored-return, flawless/no-incompatible-assertion-types, sonar/no-redundant-optional, sonar/no-try-promise, sonar/prefer-immediate-return, unicorn/no-non-function-verb-prefix, eslint-plugin/no-property-in-node, jest/no-error-equal, jest/no-unnecessary-assertion, jest/unbound-method, jest/valid-expect-with-promise",
4995
5085
  "unicorn/no-unsafe-string-replacement": "False positives under oxlint's jsPlugin scope analysis (template-literal replacements are not resolved)",
4996
5086
  "unicorn/no-useless-coercion": "Optionally type-aware: values whose type is only known through TypeScript (a `string`-typed parameter, say) are missed without parser services, so it stays in ESLint (see optionallyTypeAwareRules)",
4997
5087
  "vitest/prefer-each": "Oxlint's native port ignores where test functions are imported from, so it reports loops over non-vitest helpers and misses aliased imports (https://github.com/oxc-project/oxc/issues/27471)"
@@ -5029,7 +5119,6 @@ function isNonJsFlawlessName(name) {
5029
5119
  return name.startsWith("toml-") || name.startsWith("yaml-") || name === "no-redundant-tsconfig-options";
5030
5120
  }
5031
5121
  const KNOWN_INCOMPATIBLE_RULES = {
5032
- "jsdoc/require-param": "Oxlint applies an unexported outer function's JSDoc to a nested function (https://github.com/oxc-project/oxc/issues/27470).",
5033
5122
  "style/jsx-function-call-newline": "Formatting-rule ownership remains with ESLint and oxfmt.",
5034
5123
  "ts/no-shadow": "Oxlint skips every member of a declare namespace or declare module in .d.ts files (https://github.com/oxc-project/oxc/issues/27469).",
5035
5124
  "unicorn/no-missing-local-resource": "The preset only enables this rule for Markdown virtual files, which Oxlint cannot lint.",
@@ -5039,13 +5128,17 @@ const KNOWN_INCOMPATIBLE_RULES = {
5039
5128
  /**
5040
5129
  * Rules that take the ESLint plugin even though Oxlint ports them natively.
5041
5130
  * `unicorn/no-lonely-if` is here because its JS implementation currently has
5042
- * better autofix parity. A native preference needs no entry — that is what
5043
- * every family gets by default.
5131
+ * better autofix parity. `unicorn/no-useless-undefined` is here because the
5132
+ * native autofix breaks syntax and drops types and comments
5133
+ * (https://github.com/oxc-project/oxc/issues/28978) and the native rule misses
5134
+ * reports (https://github.com/oxc-project/oxc/issues/28979,
5135
+ * https://github.com/oxc-project/oxc/issues/28988). A native preference needs
5136
+ * no entry — that is what every family gets by default.
5044
5137
  */
5045
5138
  const JS_PLUGIN_PREFERRED_RULES = /* @__PURE__ */ new Set([
5046
- "id-length",
5047
5139
  "no-loop-func",
5048
- "unicorn/no-lonely-if"
5140
+ "unicorn/no-lonely-if",
5141
+ "unicorn/no-useless-undefined"
5049
5142
  ]);
5050
5143
  /**
5051
5144
  * Resolve one canonical ESLint rule against generated Oxlint capabilities and
@@ -5686,6 +5779,17 @@ function resolveEditorConfigOptions(cwd) {
5686
5779
  return editorConfigToPrettier(properties);
5687
5780
  }
5688
5781
  /**
5782
+ * Read a numeric `.editorconfig` value. An absent or empty value sets nothing.
5783
+ *
5784
+ * @param value - The raw property value.
5785
+ * @returns The finite number, or `undefined`.
5786
+ */
5787
+ function editorConfigNumber(value) {
5788
+ if (value === void 0 || value === "") return;
5789
+ const parsed = Number(value);
5790
+ return Number.isFinite(parsed) ? parsed : void 0;
5791
+ }
5792
+ /**
5689
5793
  * Map one `.editorconfig` section to oxfmt options, as the rule's config
5690
5794
  * loader does.
5691
5795
  *
@@ -5700,12 +5804,12 @@ function editorConfigToOxfmt(properties) {
5700
5804
  if (indentStyle === "tab" || indentStyle === "space") options["useTabs"] = indentStyle === "tab";
5701
5805
  const quoteType = properties["quote_type"];
5702
5806
  if (quoteType === "single" || quoteType === "double") options["singleQuote"] = quoteType === "single";
5703
- const indentSize = Number(properties["indent_size"]);
5704
- const tabWidth = Number(properties["tab_width"]);
5705
- if (options["useTabs"] === false && properties["indent_size"] && Number.isFinite(indentSize)) options["tabWidth"] = indentSize;
5706
- else if (properties["tab_width"] && Number.isFinite(tabWidth)) options["tabWidth"] = tabWidth;
5707
- const printWidth = Number(properties["max_line_length"]);
5708
- if (properties["max_line_length"] && Number.isFinite(printWidth)) options["printWidth"] = printWidth;
5807
+ const indentSize = editorConfigNumber(properties["indent_size"]);
5808
+ const tabWidth = editorConfigNumber(properties["tab_width"]);
5809
+ if (indentSize !== void 0 && options["useTabs"] === false) options["tabWidth"] = indentSize;
5810
+ else if (tabWidth !== void 0) options["tabWidth"] = tabWidth;
5811
+ const printWidth = editorConfigNumber(properties["max_line_length"]);
5812
+ if (printWidth !== void 0) options["printWidth"] = printWidth;
5709
5813
  const finalNewline = properties["insert_final_newline"];
5710
5814
  if (finalNewline === "true" || finalNewline === "false") options["insertFinalNewline"] = finalNewline === "true";
5711
5815
  return options;
@@ -5862,6 +5966,7 @@ function mergeRestrictedDomImportRule(rule, domPackage) {
5862
5966
  function reactRules({ domPackage, filenameCase = "kebabCase", reactCompiler = true, stylistic = true, testing = false } = {}) {
5863
5967
  const restrictedDomImport = testing ? restrictedDomImportRule(domPackage) : void 0;
5864
5968
  return {
5969
+ "flawless/no-unnecessary-prop-alias": ["error", { reportConflicts: true }],
5865
5970
  "flawless/no-unnecessary-use-callback": "error",
5866
5971
  "flawless/no-unnecessary-use-memo": "error",
5867
5972
  "flawless/purity": "error",
@@ -7382,7 +7487,8 @@ function oxlintEslintPlugin(options = {}) {
7382
7487
  /**
7383
7488
  * Base (non-React) flawless rules shared between the ESLint and oxlint
7384
7489
  * factories. The React flawless rules live in the react rule map; the
7385
- * type-aware rules live in {@link flawlessTypeAwareRules}, plus the type-aware
7490
+ * type-aware rules live in {@link flawlessTypeAwareRules} and
7491
+ * {@link flawlessTypeAwareJsxRules}, plus the type-aware
7386
7492
  * `flawless/naming-convention` in its own config; the test-only rules, and the
7387
7493
  * non-JS `flawless/no-redundant-tsconfig-options`, `flawless/toml-*` and
7388
7494
  * `flawless/yaml-*` rules are configured by their own configs.
@@ -7392,6 +7498,7 @@ function oxlintEslintPlugin(options = {}) {
7392
7498
  */
7393
7499
  function flawlessRules({ antiSlop = false, roblox = true, stylistic = true, ...arrowOptions } = {}) {
7394
7500
  return {
7501
+ "flawless/cognitive-complexity": ["warn", { threshold: 15 }],
7395
7502
  "flawless/no-export-default-arrow": "error",
7396
7503
  "flawless/no-floating-point-equality": "error",
7397
7504
  ...stylistic === false ? {} : {
@@ -7417,10 +7524,14 @@ function flawlessRules({ antiSlop = false, roblox = true, stylistic = true, ...a
7417
7524
  */
7418
7525
  function antiSlopRules({ roblox = true }) {
7419
7526
  return {
7527
+ "flawless/max-comment-length": ["error", { maximumWords: 50 }],
7420
7528
  "flawless/no-conditional-empty-object-spread": "error",
7529
+ "flawless/no-em-dash": "error",
7421
7530
  "flawless/no-known-value-widening": "error",
7422
7531
  "flawless/no-object-parameters": "error",
7423
7532
  "flawless/no-shape-in-symbol-names": "error",
7533
+ "flawless/no-trivial-functions": "error",
7534
+ "flawless/no-unknown-parameters": "error",
7424
7535
  "flawless/no-unsafe-dictionary-type": "error",
7425
7536
  ...roblox ? {} : { "flawless/no-reflect-get": "error" }
7426
7537
  };
@@ -7592,6 +7703,21 @@ function oxlintImports({ excludeFiles, roblox = true, stylistic = true } = {}) {
7592
7703
  }
7593
7704
  //#endregion
7594
7705
  //#region src/rules/javascript.ts
7706
+ /** `id-length` options shared by the ESLint rule and the native oxlint rule. */
7707
+ const ID_LENGTH_OPTIONS = {
7708
+ exceptions: [
7709
+ "_",
7710
+ "x",
7711
+ "y",
7712
+ "z",
7713
+ "a",
7714
+ "b",
7715
+ "e"
7716
+ ],
7717
+ max: 30,
7718
+ min: 2,
7719
+ properties: "never"
7720
+ };
7595
7721
  /**
7596
7722
  * Core JavaScript rules shared between the ESLint and oxlint factories.
7597
7723
  *
@@ -7796,20 +7922,6 @@ function javascriptRules({ isInEditor = false, roblox = true, stylistic = true }
7796
7922
  "valid-typeof": ["error", { requireStringLiterals: true }],
7797
7923
  "vars-on-top": "error",
7798
7924
  ...stylistic !== false ? {
7799
- "id-length": ["error", {
7800
- exceptions: [
7801
- "_",
7802
- "x",
7803
- "y",
7804
- "z",
7805
- "a",
7806
- "b",
7807
- "e"
7808
- ],
7809
- max: 30,
7810
- min: 2,
7811
- properties: "never"
7812
- }],
7813
7925
  "max-lines": ["warn", {
7814
7926
  max: 300,
7815
7927
  skipBlankLines: true,
@@ -7836,7 +7948,15 @@ function javascriptRules({ isInEditor = false, roblox = true, stylistic = true }
7836
7948
  function oxlintJavascript(options = {}) {
7837
7949
  const { excludeFiles, isInEditor = false, overrides = {}, roblox = true, stylistic = true } = options;
7838
7950
  const files = options.files?.flat() ?? ["**/*.{,c,m}[jt]s{,x}"];
7839
- return createOxlintConfigs({
7951
+ return [...stylistic !== false ? [{
7952
+ name: "isentinel/javascript/oxlint",
7953
+ ...excludeFiles ? { excludeFiles } : {},
7954
+ files,
7955
+ rules: { "id-length": ["error", {
7956
+ ...ID_LENGTH_OPTIONS,
7957
+ checkGeneric: false
7958
+ }] }
7959
+ }] : [], ...createOxlintConfigs({
7840
7960
  name: "isentinel/javascript",
7841
7961
  ...excludeFiles ? { excludeFiles } : {},
7842
7962
  files,
@@ -7854,7 +7974,7 @@ function oxlintJavascript(options = {}) {
7854
7974
  roblox,
7855
7975
  stylistic
7856
7976
  })
7857
- });
7977
+ })];
7858
7978
  }
7859
7979
  function toGlobals(source, override) {
7860
7980
  const result = {};
@@ -8754,7 +8874,6 @@ function oxlintSmallRules(options = {}) {
8754
8874
  function sonarjsRules({ isInEditor, roblox = true }) {
8755
8875
  return {
8756
8876
  "sonar/bool-param-default": "error",
8757
- "sonar/cognitive-complexity": "warn",
8758
8877
  "sonar/constructor-for-side-effects": "error",
8759
8878
  "sonar/destructuring-assignment-syntax": "error",
8760
8879
  "sonar/elseif-without-else": "off",
@@ -8770,12 +8889,10 @@ function sonarjsRules({ isInEditor, roblox = true }) {
8770
8889
  "sonar/no-duplicated-branches": "error",
8771
8890
  "sonar/no-element-overwrite": "error",
8772
8891
  "sonar/no-empty-collection": "error",
8773
- "sonar/no-floating-point-equality": "error",
8774
8892
  "sonar/no-gratuitous-expressions": "off",
8775
8893
  "sonar/no-identical-conditions": "error",
8776
8894
  "sonar/no-identical-expressions": "error",
8777
8895
  "sonar/no-identical-functions": "error",
8778
- "sonar/no-ignored-return": "error",
8779
8896
  "sonar/no-inverted-boolean-check": "error",
8780
8897
  "sonar/no-nested-conditional": "error",
8781
8898
  "sonar/no-nested-incdec": "error",
@@ -8821,7 +8938,6 @@ function sonarjsRules({ isInEditor, roblox = true }) {
8821
8938
  */
8822
8939
  function sonarjsTestRules({ jest = false, roblox = true } = {}) {
8823
8940
  return {
8824
- "sonar/no-incompatible-assertion-types": "error",
8825
8941
  ...jest ? {
8826
8942
  "sonar/no-mixed-completion-style": "error",
8827
8943
  "sonar/synchronous-suite-callback": "error"
@@ -8896,13 +9012,12 @@ function oxlintSpelling(options = {}) {
8896
9012
  * @param options - Resolved stylistic options.
8897
9013
  * @returns The rule map.
8898
9014
  */
8899
- function stylisticRules({ jsx = true, quotes = "double" } = {}) {
9015
+ function stylisticRules({ quotes = "double" } = {}) {
8900
9016
  return {
8901
9017
  "antfu/consistent-list-newline": "off",
8902
9018
  "antfu/if-newline": "off",
8903
9019
  "antfu/top-level-function": "error",
8904
9020
  "curly": ["error", "all"],
8905
- ...jsx ? { "style/jsx-curly-brace-presence": ["error", { propElementValues: "always" }] } : {},
8906
9021
  "style/lines-between-class-members": ["error", { enforce: [{
8907
9022
  blankLine: "always",
8908
9023
  next: "method",
@@ -8953,14 +9068,29 @@ function stylisticRules({ jsx = true, quotes = "double" } = {}) {
8953
9068
  ]
8954
9069
  };
8955
9070
  }
9071
+ /**
9072
+ * JSX-specific stylistic rules shared between the ESLint and oxlint factories.
9073
+ * Scoped to JSX/TSX files: a `.ts` or `.js` file cannot contain JSX, so the
9074
+ * rules would only cost a traversal there.
9075
+ *
9076
+ * @param options - Resolved stylistic options.
9077
+ * @returns The rule map.
9078
+ */
9079
+ function stylisticJsxRules({ jsx = true } = {}) {
9080
+ return jsx ? { "style/jsx-curly-brace-presence": ["error", { propElementValues: "always" }] } : {};
9081
+ }
8956
9082
  //#endregion
8957
9083
  //#region src/oxlint/configs/stylistic.ts
8958
9084
  function oxlintStylistic(options = {}) {
8959
- return createOxlintConfigs({
9085
+ return [...createOxlintConfigs({
8960
9086
  name: "isentinel/stylistic",
8961
9087
  files: [GLOB_SRC],
8962
9088
  rules: stylisticRules(options)
8963
- });
9089
+ }), ...createOxlintConfigs({
9090
+ name: "isentinel/stylistic/jsx",
9091
+ files: [GLOB_JSX, GLOB_TSX],
9092
+ rules: stylisticJsxRules(options)
9093
+ })];
8964
9094
  }
8965
9095
  //#endregion
8966
9096
  //#region src/rules/test.ts
@@ -9013,6 +9143,7 @@ function jestExtendedRules() {
9013
9143
  */
9014
9144
  function jestRules({ extended = false, isInEditor = false, roblox: isRoblox = true, stylistic = true } = {}) {
9015
9145
  return {
9146
+ "flawless/no-incompatible-assertion-types": "error",
9016
9147
  "flawless/no-shared-mocks": "error",
9017
9148
  "flawless/prefer-expect-assertions-count": "error",
9018
9149
  "jest/consistent-test-it": "error",
@@ -9092,6 +9223,7 @@ function jestRules({ extended = false, isInEditor = false, roblox: isRoblox = tr
9092
9223
  function vitestRules({ extended = false, isInEditor = false, stylistic = true } = {}) {
9093
9224
  return {
9094
9225
  "flawless/no-conditional-in-test": ["error", { allowOptionalChaining: false }],
9226
+ "flawless/no-incompatible-assertion-types": "error",
9095
9227
  "flawless/no-shared-mocks": "error",
9096
9228
  "flawless/prefer-ending-with-an-expect": ["warn", { assertFunctionNames: [
9097
9229
  "expect",
@@ -9513,7 +9645,7 @@ function oxlintTypescript(options = {}) {
9513
9645
  ];
9514
9646
  const typeAwareRules = typescriptTypeAwareRules({ roblox }) ?? {};
9515
9647
  const gatedTypeAwareRules = typeAware ? typeAwareRules : Object.fromEntries(Object.entries(typeAwareRules).filter(([rule]) => !runsInTsgolint(rule)));
9516
- return createOxlintConfigs({
9648
+ return [...createOxlintConfigs({
9517
9649
  name: "isentinel/typescript",
9518
9650
  ...excludeFiles ? { excludeFiles } : {},
9519
9651
  files,
@@ -9525,7 +9657,16 @@ function oxlintTypescript(options = {}) {
9525
9657
  ...gatedTypeAwareRules,
9526
9658
  ...erasableOnly ? erasableSyntaxOnlyRules() : {}
9527
9659
  }
9528
- });
9660
+ }), ...typeAware ? [{
9661
+ name: "isentinel/typescript/oxlint",
9662
+ ...excludeFiles ? { excludeFiles } : {},
9663
+ files,
9664
+ plugins: ["typescript"],
9665
+ rules: {
9666
+ "typescript/no-generated-empty-object-type": "error",
9667
+ "typescript/no-unsafe-enum-assignment": "error"
9668
+ }
9669
+ }] : []];
9529
9670
  }
9530
9671
  //#endregion
9531
9672
  //#region src/rules/unicorn.ts