[英]npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.7
I'm trying to install Angular using the Angular CLI but I'm getting an error when I try to run this command. 我正在尝试使用Angular CLI安装Angular,但是在尝试运行此命令时遇到错误。
Command 命令
npm install -g @angular/cli
Error: 错误:
C:\Users\abc>npm install -g @angular/cli
C:\Users\abc\AppData\Roaming\npm\ng -> C:\Users\abc\AppData\Roaming\npm\node_modules\@angular\cli\bin\ng
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.7 (node_modules\@angular\cli\node_modules\fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.7: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})
+ @angular/cli@7.3.6
updated 1 package in 102.686s
Node Version v10.15.3
节点版本
v10.15.3
This is a warning not an error, and it's because you're on Windows. 这是警告而不是错误,这是因为您使用的是Windows。 FSevents only works on Mac so it's not needed on Windows and that's why it's
SKIPPING OPTIONAL DEPENDENCY
. FSevents仅在Mac上可用,因此在Windows上不需要,这就是为什么
SKIPPING OPTIONAL DEPENDENCY
的原因。
And no as of right now there is no way to get rid of that being printed into the console so just ignore it given the fact that it's not doing anything anyways rather it's just being a bit verbose and telling you that it's not being used. 到目前为止,还没有办法消除被打印到控制台中的问题,因此,考虑到事实是它什么也不做,而只是有点冗长,告诉您它没有被使用,请忽略它。
This is because you're running on windows. 这是因为您正在Windows上运行。 A lot of apps use that library, but it only works on the Mac, so they use something else for Windows and Linux.
许多应用程序都使用该库,但是它仅在Mac上可用,因此它们在Windows和Linux上使用其他功能。 That's why it's listed as "optional".
这就是为什么它被列为“可选”的原因。 You can ignore the warning.
您可以忽略该警告。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.