【发布时间】:2021-06-06 10:43:57
【问题描述】:
所以我在 stackblitz 上有一个可用的项目,我想将其离线用于我自己的目的。作为参考,这里是我想要使用的链接-https://stackblitz.com/edit/nvs-angular-search-dropdown-istnzp。因此,我尝试下载代码并计划使用npm install 和ng serve 运行它。但我在运行npm install 时遇到很多错误,如下所示:
npm ERR! code ERESOLVE
npm ERR! ERESOLVE unable to resolve dependency tree
npm ERR!
npm ERR! While resolving: angular@0.0.0
npm ERR! Found: @angular/compiler@12.0.3
npm ERR! node_modules/@angular/compiler
npm ERR! @angular/compiler@"^12.0.3" from the root project
npm ERR!
npm ERR! Could not resolve dependency:
npm ERR! peer @angular/compiler@"7.0.4" from @angular/compiler-cli@7.0.4
npm ERR! node_modules/@angular/compiler-cli
npm ERR! dev @angular/compiler-cli@"~7.0.0" 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! See C:\Users\cnaag\AppData\Local\npm-cache\eresolve-report.txt for a full report.
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\cnaag\AppData\Local\npm-cache\_logs\2021-06-06T10_39_43_617Z-debug.log
在这方面的任何帮助都会很棒!
【问题讨论】:
-
您是否尝试过消息所暗示的内容,即。
npm install --legacy-peer-deps? -
是的,没有帮助。它仍然拒绝前进
标签: javascript angular stackblitz