Skip to content

Vue-cli-serve Could not resolve dependency #6431

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
throrin19 opened this issue Apr 22, 2021 · 3 comments
Closed

Vue-cli-serve Could not resolve dependency #6431

throrin19 opened this issue Apr 22, 2021 · 3 comments

Comments

@throrin19
Copy link

Version

4.5.12

Environment info

System:
    OS: macOS 11.2.3
    CPU: (8) x64 Intel(R) Core(TM) i7-7700HQ CPU @ 2.80GHz
  Binaries:
    Node: 14.15.4 - ~/.nvm/versions/node/v14.15.4/bin/node
    Yarn: Not Found
    npm: 7.5.2 - ~/.nvm/versions/node/v14.15.4/bin/npm
  Browsers:
    Chrome: 90.0.4430.85
    Firefox: 85.0.2
    Safari: 14.0.3
  npmGlobalPackages:
    @vue/cli: Not Found

Steps to reproduce

  • uninstall node_modules and package-lock
  • npm install

What is expected?

All packages installed correctly using vue 2 with vue-cli 4.5.12.

What is actually happening?

npm ERR! code ERESOLVE
npm ERR! ERESOLVE unable to resolve dependency tree
npm ERR! 
npm ERR! While resolving: [email protected]
npm ERR! Found: [email protected]
npm ERR! node_modules/vue
npm ERR!   dev vue@"2.6.12" from the root project
npm ERR! 
npm ERR! Could not resolve dependency:
npm ERR! peer vue@"3.0.11" from @vue/[email protected]
npm ERR! node_modules/@vue/compiler-sfc
npm ERR!   peerOptional @vue/compiler-sfc@"^3.0.0-beta.14" from @vue/[email protected]
npm ERR!   node_modules/@vue/cli-service
npm ERR!     dev @vue/cli-service@"4.5.12" from the root project
npm ERR!     1 more (@vue/cli-plugin-babel)

It works fine few days before. Now, it's not working. I think the problem is with @vue/compiler-sfc peerOptional in @vue/cli-service package

@haoqunjiang
Copy link
Member

See #6270 (comment). Please update your npm version.

@throrin19
Copy link
Author

It's no working with last npm version. To works we have to set the legacy-peer-deps flag and it's not normal...

@haoqunjiang
Copy link
Member

Then please open a new issue with a reproduction.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants