Skip to content
Advertisement

Fix the upstream dependency conflict installing NPM packages

I am trying to npm install vue-mapbox mapbox-gl, and I’m getting a dependency tree error.

I’m running Nuxt.js SSR with Vuetify and haven’t installed anything related to Mapbox prior to running this install and am getting this error.

JavaScript

What’s the right way to go about fixing this upstream dependency conflict?

Advertisement

Answer

It looks like it’s a problem with peer dependencies in the latest version of npm (v7) which is still a beta version.

Try with npm install --legacy-peer-deps. For detailed information check the blog post npm v7 Series – Beta Release! And: SemVer-Major Changes in npm v7.

Advertisement