Home > Net >  npm ERR visual studio terminal when i run NPM I
npm ERR visual studio terminal when i run NPM I

Time:06-30

Even though i've uninstalled and re-install node on my computer when ever i run npm i in my visual studio code terminal it outputs this error, although i cloned the project from github

npm ERR! argv "C:\\Program Files\\nodejs\\node.exe" "C:\\Users\\hp\\AppData\\Roaming\\npm\\node_modules\\npm\\bin\\npm-cli.js" "i"
npm ERR! node v16.15.1
npm ERR! npm  v3.10.10

npm ERR! cb.apply is not a function
npm ERR!
npm ERR! If you need help, you may report this error at:
npm ERR!     <https://github.com/npm/npm/issues>

CodePudding user response:

This likely a caching issue (which may have not been deleted when re-installing).

If you follow the steps described here it should fix your issue.

Here are the steps (Copied from the GitHub issue)

Option 1:

Follow this directory

C:\Users(your username)\AppData\Roaming

Delete the npm folder and if there is one npm cache folder.

Run npm clean cache —force ( — force is now required to clean cache)

You should be good now if not do option 2.

Option 2:

Follow this directory

C:\Users(your username)\AppData\Roaming

Delete the npm folder and if there is one mom cache folder.

Run npm clean cache —force ( — force is now required to clean cache)

Make sure everything to do with Nodejs is deleted and uninstalled.

Reinstall Nodejs.

You should be good now.

  • Related