首页 > 解决方案 > fsevents@1.2.4:、Angular 4 及更高版本不支持的平台

问题描述

我的 npm 版本是 5.6.0,我正在尝试使用命令创建 angular 4/6 项目(angular-cli)ng new。但是,我得到了错误The term 'ng' is not recognized

所以,我尝试angular-cli使用npm install -g @angular/cli.

日志

npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.4 (node_modules\@angular\cli\node_modules\fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.4: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})

+ @angular/cli@7.1.1
updated 1 package in 18.954s

但是,我仍然得到错误 => The term 'ng' is not recognized。我不确定,可能与event-steam 的后门有关

标签: angularangular-cli

解决方案


推荐阅读