从npm安装东西时出错

时间:2017-11-30 08:46:10

标签: npm

**npm WARN** codelyzer@3.2.2 requires a peer of @angular/compiler@^2.3.1 || >=4.0.0-beta <5.0.0 but none is installed. You must install peer dependencies yourself.


**npm WARN** codelyzer@3.2.2 requires a peer of @angular/core@^2.3.1 || >=4.0.0-beta <5.0.0 but none is installed. You must install peer dependencies yourself.

**npm WARN** @angular/router@3.2.4 requires a peer of @angular/core@2.2.4 but none is installed. You must install peer dependencies yourself.

**npm WARN** @angular/router@3.2.4 requires a peer of @angular/common@2.2.4 but none is installed. You must install peer dependencies yourself.

**npm WARN** @angular/router@3.2.4 requires a peer of @angular/platform-browser@2.2.4 but none is installed. You must install peer dependencies yourself.

**npm WARN** @angular/router@3.2.4 requires a peer of rxjs@5.0.0-beta.12 but none is installed. You must install peer dependencies yourself.


npm WARN @angular/compiler@2.2.4 requires a peer of @angular/core@2.2.4 but none is installed. You must install peer dependencies yourself.

**npm WARN** @angular/compiler-cli@2.3.0 requires a peer of @angular/compiler@2.3.0 but none is installed. You must install peer dependencies yourself.

**npm WARN** @angular/platform-browser-dynamic@2.3.0 requires a peer of @angular/compiler@2.3. but none is installed. You must install peer dependencies yourself.

**npm WARN** optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.1.3 (node_modules/fsevents):

**npm WARN** notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.1.3: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"ia32"})

1 个答案:

答案 0 :(得分:0)

它说你应该在2.3.1和4.0.0之间安装@ angular / compiler版本。相同的角度/核心模块和其他。查看你的package.json文件,它包含随其版本安装的所有模块的列表。如果尚未安装所有模块,请在终端中运行npm install。您可以使用npm install -g @angular/cli@latest使用最新版本。 (您可以通过编写@(版本号)来使用任何版本,如@ 2.5.5)。也许this帖子很有帮助