Skip to content

Commit 9fab1c7

Browse files
committed
feat: update to the latest eslint-plugin-vue
1 parent 9d9e39e commit 9fab1c7

File tree

7 files changed

+2103
-2077
lines changed

7 files changed

+2103
-2077
lines changed

docs/package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "nuxt-eslint-docs",
3-
"packageManager": "pnpm@10.4.1",
3+
"packageManager": "pnpm@10.6.1",
44
"private": true,
55
"scripts": {
66
"docs:dev": "nuxi dev",

package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"private": true,
33
"type": "module",
4-
"packageManager": "pnpm@10.4.1",
4+
"packageManager": "pnpm@10.6.1",
55
"version": "1.1.0",
66
"scripts": {
77
"build": "pnpm run -r build",

packages/eslint-config/src/configs/formatters.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ function mergePrettierOptions(
2424

2525
export async function formatters(
2626
options: OptionsFormatters | boolean = {},
27-
stylistic: StylisticCustomizeOptions<true>,
27+
stylistic: StylisticCustomizeOptions,
2828
): Promise<Linter.Config[]> {
2929
if (!options)
3030
return []

packages/eslint-config/src/configs/stylistic.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ import stylistic from '@stylistic/eslint-plugin'
22
import type { StylisticCustomizeOptions } from '@stylistic/eslint-plugin'
33
import type { Linter } from 'eslint'
44

5-
export default (options?: StylisticCustomizeOptions<true>): Linter.Config => {
5+
export default (options?: StylisticCustomizeOptions): Linter.Config => {
66
return {
77
name: 'nuxt/stylistic',
88
...stylistic.configs.customize(options) as Linter.Config,

packages/eslint-config/src/configs/vue.ts

+4-3
Original file line numberDiff line numberDiff line change
@@ -79,9 +79,10 @@ export default async function vue(options: NuxtESLintConfigOptions): Promise<Lin
7979
: pluginVue.processors['.vue'],
8080
rules: {
8181
...pluginVue.configs.base.rules,
82-
...pluginVue.configs['vue3-essential'].rules,
83-
...pluginVue.configs['vue3-strongly-recommended'].rules,
84-
...pluginVue.configs['vue3-recommended'].rules,
82+
83+
...pluginVue.configs['flat/essential'].map(c => c.rules).reduce((acc, c) => ({ ...acc, ...c }), {}) as Linter.Config['rules'],
84+
...pluginVue.configs['flat/strongly-recommended'].map(c => c.rules).reduce((acc, c) => ({ ...acc, ...c }), {}) as Linter.Config['rules'],
85+
...pluginVue.configs['flat/recommended'].map(c => c.rules).reduce((acc, c) => ({ ...acc, ...c }), {}) as Linter.Config['rules'],
8586

8687
// Deprecated in favor of 'vue/block-order'
8788
'vue/component-tags-order': undefined,

0 commit comments

Comments
 (0)