npm i 安装时,经常会出现如下错误
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/echarts npm ERR! echarts@"^5.2.0" from the root project npm ERR! npm ERR! Could not resolve dependency: npm ERR! peer echarts@"^4.1.0" from [email protected] npm ERR! node_modules/echarts-gl npm ERR! echarts-gl@"^1.1.1" from the root project npm ERR! 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 ERR! C:\Users\dell\AppData\Local\npm-cache\_logs\2023-04-17T04_54_59_038Z-eresolve-report.txt npm ERR! A complete log of this run can be found in: npm ERR! C:\Users\dell\AppData\Local\npm-cache\_logs\2023-04-17T04_54_59_038Z-debug-0.log
解决方法
npm i --legacy-peer-deps
引用自:https://blog.csdn.net/weixin_42624898/article/details/123694722
标签:npm,gl,ERR,dependency,ERESOLVE,安装,echarts From: https://www.cnblogs.com/xt112233/p/17325523.html