@antfu/eslint-config 3.7.2 → 3.8.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/cli.cjs CHANGED
@@ -41,8 +41,8 @@ var import_picocolors = __toESM(require("picocolors"), 1);
41
41
  var package_default = {
42
42
  name: "@antfu/eslint-config",
43
43
  type: "module",
44
- version: "3.7.2",
45
- packageManager: "pnpm@9.11.0",
44
+ version: "3.8.0",
45
+ packageManager: "pnpm@9.12.2",
46
46
  description: "Anthony's ESLint config",
47
47
  author: "Anthony Fu <anthonyfu117@hotmail.com> (https://github.com/antfu/)",
48
48
  license: "MIT",
@@ -86,7 +86,7 @@ var package_default = {
86
86
  eslint: "^9.10.0",
87
87
  "eslint-plugin-astro": "^1.2.0",
88
88
  "eslint-plugin-format": ">=0.1.0",
89
- "eslint-plugin-react-hooks": "^4.6.0",
89
+ "eslint-plugin-react-hooks": "^5.0.0",
90
90
  "eslint-plugin-react-refresh": "^0.4.4",
91
91
  "eslint-plugin-solid": "^0.14.3",
92
92
  "eslint-plugin-svelte": ">=2.35.1",
@@ -139,34 +139,34 @@ var package_default = {
139
139
  "@antfu/install-pkg": "^0.4.1",
140
140
  "@clack/prompts": "^0.7.0",
141
141
  "@eslint-community/eslint-plugin-eslint-comments": "^4.4.0",
142
- "@eslint/markdown": "^6.1.0",
143
- "@stylistic/eslint-plugin": "^2.8.0",
144
- "@typescript-eslint/eslint-plugin": "^8.7.0",
145
- "@typescript-eslint/parser": "^8.7.0",
146
- "@vitest/eslint-plugin": "^1.1.4",
142
+ "@eslint/markdown": "^6.2.0",
143
+ "@stylistic/eslint-plugin": "^2.9.0",
144
+ "@typescript-eslint/eslint-plugin": "^8.9.0",
145
+ "@typescript-eslint/parser": "^8.9.0",
146
+ "@vitest/eslint-plugin": "^1.1.7",
147
147
  "eslint-config-flat-gitignore": "^0.3.0",
148
148
  "eslint-flat-config-utils": "^0.4.0",
149
149
  "eslint-merge-processors": "^0.1.0",
150
150
  "eslint-plugin-antfu": "^2.7.0",
151
- "eslint-plugin-command": "^0.2.5",
152
- "eslint-plugin-import-x": "^4.3.0",
153
- "eslint-plugin-jsdoc": "^50.2.5",
151
+ "eslint-plugin-command": "^0.2.6",
152
+ "eslint-plugin-import-x": "^4.3.1",
153
+ "eslint-plugin-jsdoc": "^50.4.1",
154
154
  "eslint-plugin-jsonc": "^2.16.0",
155
- "eslint-plugin-n": "^17.10.3",
155
+ "eslint-plugin-n": "^17.11.1",
156
156
  "eslint-plugin-no-only-tests": "^3.3.0",
157
- "eslint-plugin-perfectionist": "^3.7.0",
157
+ "eslint-plugin-perfectionist": "^3.9.0",
158
158
  "eslint-plugin-regexp": "^2.6.0",
159
159
  "eslint-plugin-toml": "^0.11.1",
160
- "eslint-plugin-unicorn": "^55.0.0",
160
+ "eslint-plugin-unicorn": "^56.0.0",
161
161
  "eslint-plugin-unused-imports": "^4.1.4",
162
- "eslint-plugin-vue": "^9.28.0",
162
+ "eslint-plugin-vue": "^9.29.0",
163
163
  "eslint-plugin-yml": "^1.14.0",
164
164
  "eslint-processor-vue-blocks": "^0.1.2",
165
- globals: "^15.9.0",
165
+ globals: "^15.11.0",
166
166
  "jsonc-eslint-parser": "^2.4.0",
167
167
  "local-pkg": "^0.5.0",
168
168
  "parse-gitignore": "^2.0.0",
169
- picocolors: "^1.1.0",
169
+ picocolors: "^1.1.1",
170
170
  "toml-eslint-parser": "^0.10.0",
171
171
  "vue-eslint-parser": "^9.4.3",
172
172
  "yaml-eslint-parser": "^1.2.3",
@@ -175,30 +175,30 @@ var package_default = {
175
175
  devDependencies: {
176
176
  "@antfu/eslint-config": "workspace:*",
177
177
  "@antfu/ni": "^0.23.0",
178
- "@eslint-react/eslint-plugin": "^1.14.2",
178
+ "@eslint-react/eslint-plugin": "^1.15.0",
179
179
  "@eslint/config-inspector": "^0.5.4",
180
180
  "@prettier/plugin-xml": "^3.4.1",
181
- "@stylistic/eslint-plugin-migrate": "^2.8.0",
181
+ "@stylistic/eslint-plugin-migrate": "^2.9.0",
182
182
  "@types/fs-extra": "^11.0.4",
183
- "@types/node": "^22.7.2",
183
+ "@types/node": "^22.7.5",
184
184
  "@types/prompts": "^2.4.9",
185
185
  "@types/yargs": "^17.0.33",
186
186
  "@unocss/eslint-plugin": "^0.62.4",
187
187
  "astro-eslint-parser": "^1.0.3",
188
- bumpp: "^9.5.2",
189
- eslint: "^9.11.1",
190
- "eslint-plugin-astro": "^1.2.4",
188
+ bumpp: "^9.7.1",
189
+ eslint: "^9.12.0",
190
+ "eslint-plugin-astro": "^1.3.0",
191
191
  "eslint-plugin-format": "^0.1.2",
192
- "eslint-plugin-react-hooks": "^4.6.2",
192
+ "eslint-plugin-react-hooks": "^5.0.0",
193
193
  "eslint-plugin-react-refresh": "^0.4.12",
194
194
  "eslint-plugin-solid": "^0.14.3",
195
- "eslint-plugin-svelte": "^2.44.0",
195
+ "eslint-plugin-svelte": "^2.45.1",
196
196
  "eslint-typegen": "^0.3.2",
197
- esno: "^4.7.0",
198
- execa: "^9.4.0",
197
+ esno: "^4.8.0",
198
+ execa: "^9.4.1",
199
199
  "fast-glob": "^3.3.2",
200
200
  "fs-extra": "^11.2.0",
201
- jiti: "^2.0.0",
201
+ jiti: "^2.3.3",
202
202
  "lint-staged": "^15.2.10",
203
203
  "prettier-plugin-astro": "^0.14.1",
204
204
  "prettier-plugin-slidev": "^1.0.5",
@@ -208,14 +208,14 @@ var package_default = {
208
208
  "svelte-eslint-parser": "^0.41.1",
209
209
  tsup: "^8.3.0",
210
210
  tsx: "^4.19.1",
211
- typescript: "^5.6.2",
212
- vitest: "^2.1.1",
213
- vue: "^3.5.8"
211
+ typescript: "^5.6.3",
212
+ vitest: "^2.1.3",
213
+ vue: "^3.5.12"
214
214
  },
215
215
  resolutions: {
216
216
  "@eslint-community/eslint-utils": "^4.4.0",
217
- "@typescript-eslint/utils": "^8.7.0",
218
- eslint: "^9.11.1",
217
+ "@typescript-eslint/utils": "^8.9.0",
218
+ eslint: "^9.12.0",
219
219
  tsx: "^4.19.1"
220
220
  },
221
221
  "simple-git-hooks": {
@@ -262,6 +262,7 @@ var vscodeSettingsString = `
262
262
  "html",
263
263
  "markdown",
264
264
  "json",
265
+ "json5",
265
266
  "jsonc",
266
267
  "yaml",
267
268
  "toml",
package/dist/cli.js CHANGED
@@ -12,8 +12,8 @@ import c from "picocolors";
12
12
  var package_default = {
13
13
  name: "@antfu/eslint-config",
14
14
  type: "module",
15
- version: "3.7.2",
16
- packageManager: "pnpm@9.11.0",
15
+ version: "3.8.0",
16
+ packageManager: "pnpm@9.12.2",
17
17
  description: "Anthony's ESLint config",
18
18
  author: "Anthony Fu <anthonyfu117@hotmail.com> (https://github.com/antfu/)",
19
19
  license: "MIT",
@@ -57,7 +57,7 @@ var package_default = {
57
57
  eslint: "^9.10.0",
58
58
  "eslint-plugin-astro": "^1.2.0",
59
59
  "eslint-plugin-format": ">=0.1.0",
60
- "eslint-plugin-react-hooks": "^4.6.0",
60
+ "eslint-plugin-react-hooks": "^5.0.0",
61
61
  "eslint-plugin-react-refresh": "^0.4.4",
62
62
  "eslint-plugin-solid": "^0.14.3",
63
63
  "eslint-plugin-svelte": ">=2.35.1",
@@ -110,34 +110,34 @@ var package_default = {
110
110
  "@antfu/install-pkg": "^0.4.1",
111
111
  "@clack/prompts": "^0.7.0",
112
112
  "@eslint-community/eslint-plugin-eslint-comments": "^4.4.0",
113
- "@eslint/markdown": "^6.1.0",
114
- "@stylistic/eslint-plugin": "^2.8.0",
115
- "@typescript-eslint/eslint-plugin": "^8.7.0",
116
- "@typescript-eslint/parser": "^8.7.0",
117
- "@vitest/eslint-plugin": "^1.1.4",
113
+ "@eslint/markdown": "^6.2.0",
114
+ "@stylistic/eslint-plugin": "^2.9.0",
115
+ "@typescript-eslint/eslint-plugin": "^8.9.0",
116
+ "@typescript-eslint/parser": "^8.9.0",
117
+ "@vitest/eslint-plugin": "^1.1.7",
118
118
  "eslint-config-flat-gitignore": "^0.3.0",
119
119
  "eslint-flat-config-utils": "^0.4.0",
120
120
  "eslint-merge-processors": "^0.1.0",
121
121
  "eslint-plugin-antfu": "^2.7.0",
122
- "eslint-plugin-command": "^0.2.5",
123
- "eslint-plugin-import-x": "^4.3.0",
124
- "eslint-plugin-jsdoc": "^50.2.5",
122
+ "eslint-plugin-command": "^0.2.6",
123
+ "eslint-plugin-import-x": "^4.3.1",
124
+ "eslint-plugin-jsdoc": "^50.4.1",
125
125
  "eslint-plugin-jsonc": "^2.16.0",
126
- "eslint-plugin-n": "^17.10.3",
126
+ "eslint-plugin-n": "^17.11.1",
127
127
  "eslint-plugin-no-only-tests": "^3.3.0",
128
- "eslint-plugin-perfectionist": "^3.7.0",
128
+ "eslint-plugin-perfectionist": "^3.9.0",
129
129
  "eslint-plugin-regexp": "^2.6.0",
130
130
  "eslint-plugin-toml": "^0.11.1",
131
- "eslint-plugin-unicorn": "^55.0.0",
131
+ "eslint-plugin-unicorn": "^56.0.0",
132
132
  "eslint-plugin-unused-imports": "^4.1.4",
133
- "eslint-plugin-vue": "^9.28.0",
133
+ "eslint-plugin-vue": "^9.29.0",
134
134
  "eslint-plugin-yml": "^1.14.0",
135
135
  "eslint-processor-vue-blocks": "^0.1.2",
136
- globals: "^15.9.0",
136
+ globals: "^15.11.0",
137
137
  "jsonc-eslint-parser": "^2.4.0",
138
138
  "local-pkg": "^0.5.0",
139
139
  "parse-gitignore": "^2.0.0",
140
- picocolors: "^1.1.0",
140
+ picocolors: "^1.1.1",
141
141
  "toml-eslint-parser": "^0.10.0",
142
142
  "vue-eslint-parser": "^9.4.3",
143
143
  "yaml-eslint-parser": "^1.2.3",
@@ -146,30 +146,30 @@ var package_default = {
146
146
  devDependencies: {
147
147
  "@antfu/eslint-config": "workspace:*",
148
148
  "@antfu/ni": "^0.23.0",
149
- "@eslint-react/eslint-plugin": "^1.14.2",
149
+ "@eslint-react/eslint-plugin": "^1.15.0",
150
150
  "@eslint/config-inspector": "^0.5.4",
151
151
  "@prettier/plugin-xml": "^3.4.1",
152
- "@stylistic/eslint-plugin-migrate": "^2.8.0",
152
+ "@stylistic/eslint-plugin-migrate": "^2.9.0",
153
153
  "@types/fs-extra": "^11.0.4",
154
- "@types/node": "^22.7.2",
154
+ "@types/node": "^22.7.5",
155
155
  "@types/prompts": "^2.4.9",
156
156
  "@types/yargs": "^17.0.33",
157
157
  "@unocss/eslint-plugin": "^0.62.4",
158
158
  "astro-eslint-parser": "^1.0.3",
159
- bumpp: "^9.5.2",
160
- eslint: "^9.11.1",
161
- "eslint-plugin-astro": "^1.2.4",
159
+ bumpp: "^9.7.1",
160
+ eslint: "^9.12.0",
161
+ "eslint-plugin-astro": "^1.3.0",
162
162
  "eslint-plugin-format": "^0.1.2",
163
- "eslint-plugin-react-hooks": "^4.6.2",
163
+ "eslint-plugin-react-hooks": "^5.0.0",
164
164
  "eslint-plugin-react-refresh": "^0.4.12",
165
165
  "eslint-plugin-solid": "^0.14.3",
166
- "eslint-plugin-svelte": "^2.44.0",
166
+ "eslint-plugin-svelte": "^2.45.1",
167
167
  "eslint-typegen": "^0.3.2",
168
- esno: "^4.7.0",
169
- execa: "^9.4.0",
168
+ esno: "^4.8.0",
169
+ execa: "^9.4.1",
170
170
  "fast-glob": "^3.3.2",
171
171
  "fs-extra": "^11.2.0",
172
- jiti: "^2.0.0",
172
+ jiti: "^2.3.3",
173
173
  "lint-staged": "^15.2.10",
174
174
  "prettier-plugin-astro": "^0.14.1",
175
175
  "prettier-plugin-slidev": "^1.0.5",
@@ -179,14 +179,14 @@ var package_default = {
179
179
  "svelte-eslint-parser": "^0.41.1",
180
180
  tsup: "^8.3.0",
181
181
  tsx: "^4.19.1",
182
- typescript: "^5.6.2",
183
- vitest: "^2.1.1",
184
- vue: "^3.5.8"
182
+ typescript: "^5.6.3",
183
+ vitest: "^2.1.3",
184
+ vue: "^3.5.12"
185
185
  },
186
186
  resolutions: {
187
187
  "@eslint-community/eslint-utils": "^4.4.0",
188
- "@typescript-eslint/utils": "^8.7.0",
189
- eslint: "^9.11.1",
188
+ "@typescript-eslint/utils": "^8.9.0",
189
+ eslint: "^9.12.0",
190
190
  tsx: "^4.19.1"
191
191
  },
192
192
  "simple-git-hooks": {
@@ -233,6 +233,7 @@ var vscodeSettingsString = `
233
233
  "html",
234
234
  "markdown",
235
235
  "json",
236
+ "json5",
236
237
  "jsonc",
237
238
  "yaml",
238
239
  "toml",
package/dist/index.cjs CHANGED
@@ -107,7 +107,7 @@ __export(src_exports, {
107
107
  });
108
108
  module.exports = __toCommonJS(src_exports);
109
109
 
110
- // node_modules/.pnpm/tsup@8.3.0_jiti@2.0.0_postcss@8.4.47_tsx@4.19.1_typescript@5.6.2_yaml@2.5.0/node_modules/tsup/assets/cjs_shims.js
110
+ // node_modules/.pnpm/tsup@8.3.0_jiti@2.3.3_postcss@8.4.47_tsx@4.19.1_typescript@5.6.3_yaml@2.5.0/node_modules/tsup/assets/cjs_shims.js
111
111
  var getImportMetaUrl = () => typeof document === "undefined" ? new URL(`file:${__filename}`).href : document.currentScript && document.currentScript.src || new URL("main.js", document.baseURI).href;
112
112
  var importMetaUrl = /* @__PURE__ */ getImportMetaUrl();
113
113
 
@@ -424,14 +424,6 @@ async function disables() {
424
424
  "unused-imports/no-unused-vars": "off"
425
425
  }
426
426
  },
427
- {
428
- files: ["**/*.{test,spec}.([tj])s?(x)"],
429
- name: "antfu/disables/test",
430
- rules: {
431
- "antfu/no-top-level-await": "off",
432
- "no-unused-expressions": "off"
433
- }
434
- },
435
427
  {
436
428
  files: ["**/*.js", "**/*.cjs"],
437
429
  name: "antfu/disables/cjs",
@@ -1923,14 +1915,19 @@ async function test(options = {}) {
1923
1915
  files,
1924
1916
  name: "antfu/test/rules",
1925
1917
  rules: {
1926
- "node/prefer-global/process": "off",
1927
1918
  "test/consistent-test-it": ["error", { fn: "it", withinDescribe: "it" }],
1928
1919
  "test/no-identical-title": "error",
1929
1920
  "test/no-import-node-test": "error",
1930
1921
  "test/no-only-tests": isInEditor ? "off" : "error",
1931
1922
  "test/prefer-hooks-in-order": "error",
1932
1923
  "test/prefer-lowercase-title": "error",
1933
- "ts/explicit-function-return-type": "off",
1924
+ // Disables
1925
+ ...{
1926
+ "antfu/no-top-level-await": "off",
1927
+ "no-unused-expressions": "off",
1928
+ "node/prefer-global/process": "off",
1929
+ "ts/explicit-function-return-type": "off"
1930
+ },
1934
1931
  ...overrides
1935
1932
  }
1936
1933
  }
@@ -2235,7 +2232,6 @@ async function vue(options = {}) {
2235
2232
  parserVue,
2236
2233
  processorVueBlocks
2237
2234
  ] = await Promise.all([
2238
- // @ts-expect-error missing types
2239
2235
  interopDefault(import("eslint-plugin-vue")),
2240
2236
  interopDefault(import("vue-eslint-parser")),
2241
2237
  interopDefault(import("eslint-processor-vue-blocks"))