npm报错

npm报错

npm ERR! Fix the upstream dependency conflict, or retry
npm ERR! this command with --force or --legacy-peer-deps        
npm ERR! to accept an incorrect (and potentially broken) dependency resolution.
npm ERR!
npm ERR!
npm ERR! For a full report see:

修复方式一

这两种方式都可以,但是每次安装新的包都会多输入好几个字

npm install --legacy-peer-deps

npm install --force

修复方式二

使用这种方式以后在安装包就不会再出现报错了

npm config set legacy-peer-deps true

你可能感兴趣的:(前端,npm,前端,node.js)