. Advertisement .
..3..
. Advertisement .
..4..
If you have ever found the error “npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for [email protected]” the npm which stands for Node Package Manager is a JavaScript utility used for automating development tasks. This error is a part of the Node.js which is also an open-source and cross-platform. This blog will help you to fix this error.
When Do You Get The Error “npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for [email protected]”?
You may get the following error when attempting to install a new fsevents library.
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: [email protected] (node_modules\watchpack-chokidar2\node_modules\fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for [email protected]: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: [email protected] (node_modules\@angular\compiler-cli\node_modules\fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for [email protected]: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: [email protected] (node_modules\fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for [email protected]: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: [email protected] (node_modules\webpack-dev-server\node_modules\fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for [email protected]: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: [email protected] (node_modules\karma\node_modules\fsevents):
How To Fix The Error “npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for [email protected]”?
Approach 1: Install library force install with the command below
Simply install library force install with the command below to resolve this error, but don’t worry. You could also include it in your .package.json’s”optionalDependencies”: [] section. If you wanted to start over and install from scratch, it should remove the warnings, but ensure you use the right version.
npm install -f
Approach 2: There is a PR here to correct this behavior
“npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for [email protected]” is not an error, it’s a caution. It happens because the package that provides “Native Access to Mac OS-X FSEvents”, fsevents is an optional dependency. It is only used when the project is runned in a macOS environment.
Additionally, because your project is being executed on Windows, fsevents are ignored as being unimportant.
There is a PR here to correct this behavior: https://github.com/npm/cli/pull/169.
This PR is very useful for you. It will make your error disappeear and your program will run well without any errors. Let’s apply it to get your desired results.
Conclusion
We hope you will enjoy our blog post on how to solve the bug “npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for [email protected]“. Please leave a comment if you have any further questions or concerns regarding installing pip on your machine. Thank you for taking the time to read; we are always delighted anytime one of our pieces can give important information on this topic!
Read more
Leave a comment