Skip to content Skip to sidebar Skip to footer

Can't Install Any Npm Package, Error 4058

I'm trying to install Grunt on my project. It used to work perfectly, but now for some reason, it does not. Every time i try to install Grunt, I got this error: npm ERR! path C:\i

Solution 1:

Try these steps:

  • Delete package-lock.json and run NPM again.
  • Ensure no other processes of node.js are running (check task manager)
  • If you are using visual studio code, close it and try running npm install again.
  • If all else fails, restart your computer.

See thread here: https://github.com/npm/npm/issues/17444

Solution 2:

For me the reason was Dropbox (my NodeJS project being somewhere deep in the Dropbox folder). I suspended the synchronisation, tried npm install again and it installed without error. Then of course I resumed the synchronisation.

Solution 3:

you should not forget to goto the project folder by cd "nameofproject" and then "npm start" is work.

Solution 4:

  • delete package-lock.josn and node_modules
  • clear npm cache by npm cache clear --force
  • restart VS Code
  • running npm installagain

Solution 5:

Try this:

  1. Check if you have created an inside folder with the same folder name.

  2. If 2 folders exist with the same name (Delete that 1st folder)

  3. Go to terminal: npm start

Post a Comment for "Can't Install Any Npm Package, Error 4058"