@oxlint/migrate 1.65.0 → 1.67.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import { a as nurseryRules, i as buildUnsupportedRuleExplanations, n as preFixForJsPlugins, o as rules_exports, r as isOffValue, s as normalizeRuleToCanonical, t as main } from "../src-
|
|
2
|
+
import { a as nurseryRules, i as buildUnsupportedRuleExplanations, n as preFixForJsPlugins, o as rules_exports, r as isOffValue, s as normalizeRuleToCanonical, t as main } from "../src-lamrnkq_.mjs";
|
|
3
3
|
import { program } from "commander";
|
|
4
4
|
import { existsSync, readFileSync, renameSync, writeFileSync } from "node:fs";
|
|
5
5
|
import path from "node:path";
|
|
@@ -30,7 +30,7 @@ const loadESLintConfig = async (filePath) => {
|
|
|
30
30
|
};
|
|
31
31
|
//#endregion
|
|
32
32
|
//#region package.json
|
|
33
|
-
var version = "1.
|
|
33
|
+
var version = "1.67.0";
|
|
34
34
|
//#endregion
|
|
35
35
|
//#region src/walker/comments/replaceRuleDirectiveComment.ts
|
|
36
36
|
const allRulesSet = new Set(Object.values(rules_exports).flat());
|
package/dist/src/index.d.mts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
//#region node_modules/.pnpm/oxlint@1.
|
|
1
|
+
//#region node_modules/.pnpm/oxlint@1.67.0_oxlint-tsgolint@0.23.0/node_modules/oxlint/dist/index.d.ts
|
|
2
2
|
//#region src-js/package/config.generated.d.ts
|
|
3
3
|
type AllowWarnDeny = ("allow" | "off" | "warn" | "error" | "deny") | number;
|
|
4
4
|
type GlobalValue = "readonly" | "writable" | "off";
|
|
@@ -503,6 +503,7 @@ interface DummyRuleMap {
|
|
|
503
503
|
"grouped-accessor-pairs"?: DummyRule;
|
|
504
504
|
"guard-for-in"?: DummyRule;
|
|
505
505
|
"id-length"?: DummyRule;
|
|
506
|
+
"id-match"?: DummyRule;
|
|
506
507
|
"import/consistent-type-specifier-style"?: DummyRule;
|
|
507
508
|
"import/default"?: DummyRule;
|
|
508
509
|
"import/export"?: DummyRule;
|
|
@@ -513,6 +514,7 @@ interface DummyRuleMap {
|
|
|
513
514
|
"import/max-dependencies"?: DummyRule;
|
|
514
515
|
"import/named"?: DummyRule;
|
|
515
516
|
"import/namespace"?: DummyRule;
|
|
517
|
+
"import/newline-after-import"?: DummyRule;
|
|
516
518
|
"import/no-absolute-path"?: DummyRule;
|
|
517
519
|
"import/no-amd"?: DummyRule;
|
|
518
520
|
"import/no-anonymous-default-export"?: DummyRule;
|
|
@@ -726,6 +728,7 @@ interface DummyRuleMap {
|
|
|
726
728
|
"no-global-assign"?: DummyRule;
|
|
727
729
|
"no-implicit-coercion"?: DummyRule;
|
|
728
730
|
"no-implicit-globals"?: DummyRule;
|
|
731
|
+
"no-implied-eval"?: DummyRule;
|
|
729
732
|
"no-import-assign"?: DummyRule;
|
|
730
733
|
"no-inline-comments"?: DummyRule;
|
|
731
734
|
"no-inner-declarations"?: DummyRule;
|
|
@@ -805,6 +808,7 @@ interface DummyRuleMap {
|
|
|
805
808
|
"no-void"?: DummyRule;
|
|
806
809
|
"no-warning-comments"?: DummyRule;
|
|
807
810
|
"no-with"?: DummyRule;
|
|
811
|
+
"node/callback-return"?: DummyRule;
|
|
808
812
|
"node/global-require"?: DummyRule;
|
|
809
813
|
"node/handle-callback-err"?: DummyRule;
|
|
810
814
|
"node/no-exports-assign"?: DummyRule;
|
|
@@ -912,6 +916,7 @@ interface DummyRuleMap {
|
|
|
912
916
|
"react/no-is-mounted"?: DummyRule;
|
|
913
917
|
"react/no-multi-comp"?: DummyRule;
|
|
914
918
|
"react/no-namespace"?: DummyRule;
|
|
919
|
+
"react/no-object-type-as-default-prop"?: DummyRule;
|
|
915
920
|
"react/no-react-children"?: DummyRule;
|
|
916
921
|
"react/no-redundant-should-component-update"?: DummyRule;
|
|
917
922
|
"react/no-render-return-value"?: DummyRule;
|
|
@@ -921,6 +926,7 @@ interface DummyRuleMap {
|
|
|
921
926
|
"react/no-unescaped-entities"?: DummyRule;
|
|
922
927
|
"react/no-unknown-property"?: DummyRule;
|
|
923
928
|
"react/no-unsafe"?: DummyRule;
|
|
929
|
+
"react/no-unstable-nested-components"?: DummyRule;
|
|
924
930
|
"react/no-will-update-set-state"?: DummyRule;
|
|
925
931
|
"react/only-export-components"?: DummyRule;
|
|
926
932
|
"react/prefer-es6-class"?: DummyRule;
|
|
@@ -1062,6 +1068,7 @@ interface DummyRuleMap {
|
|
|
1062
1068
|
"unicorn/escape-case"?: DummyRule;
|
|
1063
1069
|
"unicorn/explicit-length-check"?: DummyRule;
|
|
1064
1070
|
"unicorn/filename-case"?: DummyRule;
|
|
1071
|
+
"unicorn/import-style"?: DummyRule;
|
|
1065
1072
|
"unicorn/new-for-builtins"?: DummyRule;
|
|
1066
1073
|
"unicorn/no-abusive-eslint-disable"?: DummyRule;
|
|
1067
1074
|
"unicorn/no-accessor-recursion"?: DummyRule;
|
|
@@ -1211,6 +1218,7 @@ interface DummyRuleMap {
|
|
|
1211
1218
|
"vitest/no-test-prefixes"?: DummyRule;
|
|
1212
1219
|
"vitest/no-test-return-statement"?: DummyRule;
|
|
1213
1220
|
"vitest/no-unneeded-async-expect-function"?: DummyRule;
|
|
1221
|
+
"vitest/padding-around-after-all-blocks"?: DummyRule;
|
|
1214
1222
|
"vitest/prefer-called-exactly-once-with"?: DummyRule;
|
|
1215
1223
|
"vitest/prefer-called-once"?: DummyRule;
|
|
1216
1224
|
"vitest/prefer-called-times"?: DummyRule;
|
|
@@ -1258,26 +1266,36 @@ interface DummyRuleMap {
|
|
|
1258
1266
|
"vue/define-props-destructuring"?: DummyRule;
|
|
1259
1267
|
"vue/max-props"?: DummyRule;
|
|
1260
1268
|
"vue/no-arrow-functions-in-watch"?: DummyRule;
|
|
1269
|
+
"vue/no-computed-properties-in-data"?: DummyRule;
|
|
1261
1270
|
"vue/no-deprecated-data-object-declaration"?: DummyRule;
|
|
1262
1271
|
"vue/no-deprecated-delete-set"?: DummyRule;
|
|
1263
1272
|
"vue/no-deprecated-destroyed-lifecycle"?: DummyRule;
|
|
1264
1273
|
"vue/no-deprecated-events-api"?: DummyRule;
|
|
1265
1274
|
"vue/no-deprecated-model-definition"?: DummyRule;
|
|
1275
|
+
"vue/no-deprecated-props-default-this"?: DummyRule;
|
|
1266
1276
|
"vue/no-deprecated-vue-config-keycodes"?: DummyRule;
|
|
1267
1277
|
"vue/no-export-in-script-setup"?: DummyRule;
|
|
1278
|
+
"vue/no-expose-after-await"?: DummyRule;
|
|
1268
1279
|
"vue/no-import-compiler-macros"?: DummyRule;
|
|
1269
1280
|
"vue/no-lifecycle-after-await"?: DummyRule;
|
|
1270
1281
|
"vue/no-multiple-slot-args"?: DummyRule;
|
|
1271
1282
|
"vue/no-required-prop-with-default"?: DummyRule;
|
|
1283
|
+
"vue/no-shared-component-data"?: DummyRule;
|
|
1272
1284
|
"vue/no-this-in-before-route-enter"?: DummyRule;
|
|
1285
|
+
"vue/no-watch-after-await"?: DummyRule;
|
|
1273
1286
|
"vue/prefer-import-from-vue"?: DummyRule;
|
|
1274
1287
|
"vue/require-default-export"?: DummyRule;
|
|
1288
|
+
"vue/require-render-return"?: DummyRule;
|
|
1289
|
+
"vue/require-slots-as-functions"?: DummyRule;
|
|
1275
1290
|
"vue/require-typed-ref"?: DummyRule;
|
|
1276
1291
|
"vue/return-in-computed-property"?: DummyRule;
|
|
1292
|
+
"vue/return-in-emits-validator"?: DummyRule;
|
|
1277
1293
|
"vue/valid-define-emits"?: DummyRule;
|
|
1294
|
+
"vue/valid-define-options"?: DummyRule;
|
|
1278
1295
|
"vue/valid-define-props"?: DummyRule;
|
|
1296
|
+
"vue/valid-next-tick"?: DummyRule;
|
|
1279
1297
|
yoda?: DummyRule;
|
|
1280
|
-
[k: string]: DummyRule;
|
|
1298
|
+
[k: string]: DummyRule | undefined;
|
|
1281
1299
|
}
|
|
1282
1300
|
/**
|
|
1283
1301
|
* Configure the behavior of linter plugins.
|
package/dist/src/index.mjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { t as main } from "../src-
|
|
1
|
+
import { t as main } from "../src-lamrnkq_.mjs";
|
|
2
2
|
export { main as default };
|
|
@@ -541,6 +541,7 @@ const styleRules = [
|
|
|
541
541
|
"grouped-accessor-pairs",
|
|
542
542
|
"guard-for-in",
|
|
543
543
|
"id-length",
|
|
544
|
+
"id-match",
|
|
544
545
|
"init-declarations",
|
|
545
546
|
"logical-assignment-operators",
|
|
546
547
|
"max-params",
|
|
@@ -585,6 +586,7 @@ const styleRules = [
|
|
|
585
586
|
"import/exports-last",
|
|
586
587
|
"import/first",
|
|
587
588
|
"import/group-exports",
|
|
589
|
+
"import/newline-after-import",
|
|
588
590
|
"import/no-anonymous-default-export",
|
|
589
591
|
"import/no-duplicates",
|
|
590
592
|
"import/no-mutable-exports",
|
|
@@ -640,6 +642,7 @@ const styleRules = [
|
|
|
640
642
|
"jest/require-hook",
|
|
641
643
|
"jest/require-top-level-describe",
|
|
642
644
|
"jsdoc/require-throws-description",
|
|
645
|
+
"node/callback-return",
|
|
643
646
|
"node/global-require",
|
|
644
647
|
"node/no-exports-assign",
|
|
645
648
|
"promise/avoid-new",
|
|
@@ -751,6 +754,7 @@ const styleRules = [
|
|
|
751
754
|
"vitest/no-test-prefixes",
|
|
752
755
|
"vitest/no-test-return-statement",
|
|
753
756
|
"vitest/no-unneeded-async-expect-function",
|
|
757
|
+
"vitest/padding-around-after-all-blocks",
|
|
754
758
|
"vitest/prefer-called-exactly-once-with",
|
|
755
759
|
"vitest/prefer-called-once",
|
|
756
760
|
"vitest/prefer-called-times",
|
|
@@ -795,6 +799,7 @@ const suspiciousRules = [
|
|
|
795
799
|
"block-scoped-var",
|
|
796
800
|
"no-extend-native",
|
|
797
801
|
"no-extra-bind",
|
|
802
|
+
"no-implied-eval",
|
|
798
803
|
"no-new",
|
|
799
804
|
"no-shadow",
|
|
800
805
|
"no-underscore-dangle",
|
|
@@ -818,6 +823,7 @@ const suspiciousRules = [
|
|
|
818
823
|
"react/jsx-no-comment-textnodes",
|
|
819
824
|
"react/jsx-no-script-url",
|
|
820
825
|
"react/no-namespace",
|
|
826
|
+
"react/no-unstable-nested-components",
|
|
821
827
|
"react/react-in-jsx-scope",
|
|
822
828
|
"react/style-prop-object",
|
|
823
829
|
"typescript/consistent-return",
|
|
@@ -919,6 +925,7 @@ const restrictionRules = [
|
|
|
919
925
|
"typescript/prefer-literal-enum-member",
|
|
920
926
|
"typescript/promise-function-async",
|
|
921
927
|
"typescript/use-unknown-in-catch-callback-variable",
|
|
928
|
+
"unicorn/import-style",
|
|
922
929
|
"unicorn/no-abusive-eslint-disable",
|
|
923
930
|
"unicorn/no-anonymous-default-export",
|
|
924
931
|
"unicorn/no-array-for-each",
|
|
@@ -1159,19 +1166,29 @@ const correctnessRules = [
|
|
|
1159
1166
|
"vitest/valid-title",
|
|
1160
1167
|
"vitest/warn-todo",
|
|
1161
1168
|
"vue/no-arrow-functions-in-watch",
|
|
1169
|
+
"vue/no-computed-properties-in-data",
|
|
1162
1170
|
"vue/no-deprecated-data-object-declaration",
|
|
1163
1171
|
"vue/no-deprecated-delete-set",
|
|
1164
1172
|
"vue/no-deprecated-destroyed-lifecycle",
|
|
1165
1173
|
"vue/no-deprecated-events-api",
|
|
1166
1174
|
"vue/no-deprecated-model-definition",
|
|
1175
|
+
"vue/no-deprecated-props-default-this",
|
|
1167
1176
|
"vue/no-deprecated-vue-config-keycodes",
|
|
1168
1177
|
"vue/no-export-in-script-setup",
|
|
1178
|
+
"vue/no-expose-after-await",
|
|
1169
1179
|
"vue/no-lifecycle-after-await",
|
|
1180
|
+
"vue/no-shared-component-data",
|
|
1170
1181
|
"vue/no-this-in-before-route-enter",
|
|
1182
|
+
"vue/no-watch-after-await",
|
|
1171
1183
|
"vue/prefer-import-from-vue",
|
|
1184
|
+
"vue/require-render-return",
|
|
1185
|
+
"vue/require-slots-as-functions",
|
|
1172
1186
|
"vue/return-in-computed-property",
|
|
1187
|
+
"vue/return-in-emits-validator",
|
|
1173
1188
|
"vue/valid-define-emits",
|
|
1189
|
+
"vue/valid-define-options",
|
|
1174
1190
|
"vue/valid-define-props",
|
|
1191
|
+
"vue/valid-next-tick",
|
|
1175
1192
|
"typescript/no-dupe-class-members",
|
|
1176
1193
|
"typescript/no-loss-of-precision",
|
|
1177
1194
|
"typescript/no-unused-expressions",
|
|
@@ -1182,6 +1199,7 @@ const perfRules = [
|
|
|
1182
1199
|
"no-useless-call",
|
|
1183
1200
|
"react/jsx-no-constructed-context-values",
|
|
1184
1201
|
"react/no-array-index-key",
|
|
1202
|
+
"react/no-object-type-as-default-prop",
|
|
1185
1203
|
"react-perf/jsx-no-jsx-as-prop",
|
|
1186
1204
|
"react-perf/jsx-no-new-array-as-prop",
|
|
1187
1205
|
"react-perf/jsx-no-new-function-as-prop",
|
|
@@ -1306,6 +1324,7 @@ var unsupportedRules = {
|
|
|
1306
1324
|
"n/no-restricted-import": "No need to implement, already implemented by `no-restricted-imports` rule.",
|
|
1307
1325
|
"n/no-restricted-require": "No need to implement, already implemented by `no-restricted-imports` rule.",
|
|
1308
1326
|
"import/order": "Not implementing this in Oxlint as its behavior is covered very well by [Oxfmt's import sorting](https://oxc.rs/docs/guide/usage/formatter/sorting.html).",
|
|
1327
|
+
"unicorn/template-indent": "Stylistic rule.",
|
|
1309
1328
|
"jsdoc/type-formatting": "Experimental rule in the original plugin, may reconsider once stable.",
|
|
1310
1329
|
"jsdoc/convert-to-jsdoc-comments": "Experimental rule in the original plugin, may reconsider once stable.",
|
|
1311
1330
|
"jsdoc/check-examples": "Deprecated.",
|
|
@@ -1314,7 +1333,6 @@ var unsupportedRules = {
|
|
|
1314
1333
|
"jest/no-error-equal": "Requires type information. Not currently possible to implement in oxlint.",
|
|
1315
1334
|
"jest/valid-expect-with-promise": "Requires type information. Not currently possible to implement in oxlint.",
|
|
1316
1335
|
"vitest/unbound-method": "Requires type information. Not currently possible to implement in oxlint.",
|
|
1317
|
-
"vitest/prefer-vi-mocked": "Requires type information. Not currently possible to implement in oxlint.",
|
|
1318
1336
|
"eslint/no-process-env": "Deprecated, replaced by `node/no-process-env`, which we already support.",
|
|
1319
1337
|
"eslint/no-new-require": "Deprecated, replaced by `node/no-new-require`, which we already support.",
|
|
1320
1338
|
"eslint/no-buffer-constructor": "Replaced by `node/no-deprecated-api`.",
|
|
@@ -1361,6 +1379,8 @@ var unsupportedRules = {
|
|
|
1361
1379
|
"react/use-memo": "React Compiler rules will not be implemented in oxlint for now, as they require integration with the react compiler itself. These rules can be used via JS Plugins if desired.",
|
|
1362
1380
|
"react/incompatible-library": "React Compiler rules will not be implemented in oxlint for now, as they require integration with the react compiler itself. These rules can be used via JS Plugins if desired.",
|
|
1363
1381
|
"react/automatic-effect-dependencies": "React Compiler rules will not be implemented in oxlint for now, as they require integration with the react compiler itself. These rules can be used via JS Plugins if desired.",
|
|
1382
|
+
"react/memo-dependencies": "React Compiler rules will not be implemented in oxlint for now, as they require integration with the react compiler itself. These rules can be used via JS Plugins if desired.",
|
|
1383
|
+
"react/exhaustive-effect-dependencies": "React Compiler rules will not be implemented in oxlint for now, as they require integration with the react compiler itself. These rules can be used via JS Plugins if desired.",
|
|
1364
1384
|
"react/capitalized-calls": "React Compiler rules will not be implemented in oxlint for now, as they require integration with the react compiler itself. These rules can be used via JS Plugins if desired.",
|
|
1365
1385
|
"react/fbt": "React Compiler rules will not be implemented in oxlint for now, as they require integration with the react compiler itself. These rules can be used via JS Plugins if desired.",
|
|
1366
1386
|
"react/fire": "React Compiler rules will not be implemented in oxlint for now, as they require integration with the react compiler itself. These rules can be used via JS Plugins if desired.",
|
|
@@ -1387,6 +1407,7 @@ var unsupportedRules = {
|
|
|
1387
1407
|
"react/require-optimization": "This rule only applies to legacy class components, which are not widely used in modern React.",
|
|
1388
1408
|
"react/prefer-read-only-props": "This rule is niche and primarily applies to legacy class components, which are not widely used in modern React.",
|
|
1389
1409
|
"react/prop-types": "PropTypes are ignored in React 19, and TypeScript + the `no-unsafe-xxx` rules already catches unsafe props in most cases.",
|
|
1410
|
+
"react/prefer-stateless-function": "Superseded by `react/prefer-function-component`, which we support.",
|
|
1390
1411
|
"typescript/sort-type-constituents": "Deprecated, replaced by `perfectionist/sort-intersection-types` and `perfectionist/sort-union-types` rules.",
|
|
1391
1412
|
"typescript/no-type-alias": "Deprecated, replaced by `typescript-eslint/consistent-type-definitions` rule.",
|
|
1392
1413
|
"typescript/typedef": "Deprecated.",
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@oxlint/migrate",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.67.0",
|
|
4
4
|
"description": "Generates a `.oxlintrc.json` from a existing eslint flat config",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"eslint",
|
|
@@ -40,13 +40,13 @@
|
|
|
40
40
|
"dependencies": {
|
|
41
41
|
"commander": "^14.0.0",
|
|
42
42
|
"globals": "^17.0.0",
|
|
43
|
-
"oxc-parser": "^0.
|
|
43
|
+
"oxc-parser": "^0.132.0",
|
|
44
44
|
"tinyglobby": "^0.2.14"
|
|
45
45
|
},
|
|
46
46
|
"devDependencies": {
|
|
47
47
|
"@antfu/eslint-config": "^8.0.0",
|
|
48
48
|
"@babel/eslint-plugin": "^7.27.1",
|
|
49
|
-
"@e18e/eslint-plugin": "^0.
|
|
49
|
+
"@e18e/eslint-plugin": "^0.5.0",
|
|
50
50
|
"@eslint-react/eslint-plugin": "^4.0.0",
|
|
51
51
|
"@eslint/js": "^10.0.0",
|
|
52
52
|
"@logux/eslint-config": "^57.0.0",
|
|
@@ -83,9 +83,9 @@
|
|
|
83
83
|
"husky": "^9.1.7",
|
|
84
84
|
"lint-staged": "^16.1.2",
|
|
85
85
|
"next": "^16.0.0",
|
|
86
|
-
"oxfmt": "^0.
|
|
87
|
-
"oxlint": "^1.
|
|
88
|
-
"oxlint-tsgolint": "^0.
|
|
86
|
+
"oxfmt": "^0.51.0",
|
|
87
|
+
"oxlint": "^1.67.0",
|
|
88
|
+
"oxlint-tsgolint": "^0.23.0",
|
|
89
89
|
"tsdown": "^0.22.0",
|
|
90
90
|
"typescript": "^6.0.0",
|
|
91
91
|
"typescript-eslint": "^8.35.0",
|
|
@@ -94,5 +94,5 @@
|
|
|
94
94
|
"lint-staged": {
|
|
95
95
|
"*": "oxfmt --no-error-on-unmatched-pattern"
|
|
96
96
|
},
|
|
97
|
-
"packageManager": "pnpm@11.
|
|
97
|
+
"packageManager": "pnpm@11.2.2"
|
|
98
98
|
}
|