Attempting to add npm i -D eslint-plugin-svelte after npm i -D eslint @antfu/eslint-config causes a conflicting peer dependency
Reproduction
mkdir test && cd test && npm create -y && npm i -D eslint @antfu/eslint-config eslint-plugin-svelte && npm i
System Info
'Log files:
C:\Users\mrvau\AppData\Local\npm-cache\_logs\2024-06-13T21_25_33_052Z-debug-0.log
# npm resolution error report
While resolving: @antfu/eslint-config@2.21.1
Found: svelte-eslint-parser@0.37.0
node_modules/svelte-eslint-parser
peerOptional svelte-eslint-parser@"^0.37.0" from eslint-plugin-perfectionist@2.11.0
node_modules/eslint-plugin-perfectionist
eslint-plugin-perfectionist@"^2.10.0" from @antfu/eslint-config@2.21.1
node_modules/@antfu/eslint-config
dev @antfu/eslint-config@"^2.21.1" from the root project
svelte-eslint-parser@"^0.37.0" from eslint-plugin-svelte@2.39.3
node_modules/eslint-plugin-svelte
dev eslint-plugin-svelte@"^2.39.3" from the root project
peerOptional eslint-plugin-svelte@">=2.35.1" from @antfu/eslint-config@2.21.1
node_modules/@antfu/eslint-config
dev @antfu/eslint-config@"^2.21.1" from the root project
Could not resolve dependency:
peerOptional svelte-eslint-parser@"^0.33.1" from @antfu/eslint-config@2.21.1
node_modules/@antfu/eslint-config
dev @antfu/eslint-config@"^2.21.1" from the root project
Conflicting peer dependency: svelte-eslint-parser@0.33.1
node_modules/svelte-eslint-parser
peerOptional svelte-eslint-parser@"^0.33.1" from @antfu/eslint-config@2.21.1
node_modules/@antfu/eslint-config
dev @antfu/eslint-config@"^2.21.1" from the root project
Fix the upstream dependency conflict, or retry
this command with --force or --legacy-peer-deps
to accept an incorrect (and potentially broken) dependency resolution.
Describe the bug
Attempting to add
npm i -D eslint-plugin-svelte
afternpm i -D eslint @antfu/eslint-config
causes a conflicting peer dependencyReproduction
mkdir test && cd test && npm create -y && npm i -D eslint @antfu/eslint-config eslint-plugin-svelte && npm i
System Info
Used Package Manager
npm
Validations
Contributions