![](/img/trans.png)
[英]How to clear angular warning messages while installing packages using NPM
[英]Npm Angular Warning while installing packages
我在尝试安装软件包时收到 npm 警告:
$ npm install
npm WARN @angular/compiler-cli@10.0.2 requires a peer of @angular/compiler@10.0.2 but none is installed. You must install peer dependencies yourself.
audited 1595 packages in 18.719s
58 packages are looking for funding
run `npm fund` for details
found 294 low severity vulnerabilities
run `npm audit fix` to fix them, or `npm audit` for details
为了解决上述对等问题警告,我尝试安装该对等依赖项并收到以下警告:
$ npm install @angular/compiler@10.0.2
npm WARN @angular/platform-browser-dynamic@8.2.14 requires a peer of @angular/compiler@8.2.14 but none is installed. You must install peer dependencies yourself.
npm WARN codelyzer@5.2.1 requires a peer of @angular/compiler@>=2.3.1 <10.0.0 || >9.0.0-beta <10.0.0 || >9.1.0-beta <10.0.0 || >9.2.0-beta <10.0.0 but none is installed. You must install peer dependencies yourself.
+ @angular/compiler@10.0.2
added 1 package from 1 contributor, updated 1 package and audited 1596 packages in 15.701s
58 packages are looking for funding
run `npm fund` for details
found 294 low severity vulnerabilities
run `npm audit fix` to fix them, or `npm audit` for details
谁能帮我这个?
您的 package.json 不会有@angular/compiler@10.0.2
某些库依赖于节点包世界中的其他库,例如在这种情况下@angular/compiler-cli@10.0.2
依赖或使用@angular/compiler@10.0.2
的某些功能@angular/compiler@10.0.2
。
只需将@angular/compiler@10^
添加到您的package.json
并且下次运行 npm 安装时将不会收到警告
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.