Before clearing cache
npm cache clear
npm is working fine. After clearing cache, it is not working. The error log below suggest problem wi
Environment path may have been removed.
Check it by typing,
npm config get prefix
This must be the location where the npm binaries are found.
In windows, c:/users/username/AppData/Roaming/npm
is the place where they are found.
Add this location to the environment variable. It should work fine.
(Control Panel -> Search for 'Environment Variables' and click on a button with that name -> edit Path -> add the above location)
at npm@6.8.0 the command that is been supported is npm cache verify
I had to install the latest version of NodeJS. That worked out for me.
This worked for me:
npm cache clean --force
try this one
npm cache clean --force
after that run
npm cache verify
"As of npm@5, the npm cache self-heals from corruption issues and data extracted from the cache is guaranteed to be valid. If you want to make sure everything is consistent, use
npm cache verify
instead."