I have no idea what is happening here. Hoping someone can help me.
This works great in my mac. But same process in Windows and npm install crashes. This is what I ge
After countless hours of debugging and researching, I decided to install in a different machine to see if the problem was with my Node installation. It worked.
So for everyone who may come across this, know that the possibility to uninstall node and delete NPM will be there. This is what I did. I believe it is the safest way to solve the problem and all the rest of your applications installed in your machine will still work. I credit this answer for these steps, although I had other npm and node_modules in other locations. So do a quick search for these and unless they are part of an application, make sure they are deleted as well.
Uninstall from Programs & Features with the uninstaller.
Reboot (or you probably can get away with killing all node-related processes from Task Manager).
Look for these folders and remove them (and their contents) if any still exist. Depending on the version you installed, UAC settings, and CPU architecture, these may or may not exist:
C:\Program Files (x86)\Nodejs
C:\Program Files\Nodejs
C:\Users\{User}\AppData\Roaming\npm
(or %appdata%\npm
)C:\Users\{User}\AppData\Roaming\npm-cache
(or %appdata%\npm-cache
)C:\Users\{User}\.npmrc
(and possibly check for that without the .
prefix too)Check your %PATH% environment variable to ensure no references to Nodejs
or npm
exist.
If it's still not uninstalled, type where node
at the command prompt and you'll see where it resides -- delete that (and probably the parent directory) too.
Reboot, for good measure.
update and then install again
npm install -g npm-check-updates
npm install
add this to fix any errors
npm audit fix
Please read the error carefully. It's saying :
fsevents@1.0.17: wanted {"os":"darwin","arch":"any"}
The FSEvents API in OS X allows applications to register for notifications of changes to a given directory tree.
It needs OS X, Because some of npm dependencies are using fsevents that's by It's breaking in windows.
https://github.com/strongloop/fsevents
Update:
As you told It's working without fsevents then you can follow these steps:
install npm-check-updates and try again.
npm install -g npm-check-updates
ncu -u #It will update the npm dependencies.
rm -fr node_modules
npm install
It will update the dependencies and install the dependencies.
Hope It will work :)
The only solution that worked for me was deleting npm and npm-cache from C:\Users(your username)\AppData\Roaming Uninstalling nodejs and reinstalling it
please try to open the console as a administrator. do right Click on the commandLine and select "open as administrator" then try installing dependency.