I just uninstalled Node and reinstalled it using homebrew. I first installed without npm. Then uninstall this version and install Node with npm number.
The installation was successful, but now I can not use NPM.
Everything I try using NPM, I get an error
module.js:338
throw err;
^
Error: Cannot find module 'are-we-there-yet'
at Function.Module._resolveFilename (module.js:336:15)
at Function.Module._load (module.js:286:25)
at Module.require (module.js:365:17)
at require (module.js:384:17)
at Object.<anonymous> (/usr/local/lib/node_modules/npm/node_modules/npmlog/log.js:2:16)
at Module._compile (module.js:434:26)
at Object.Module._extensions..js (module.js:452:10)
at Module.load (module.js:355:32)
at Function.Module._load (module.js:310:12)
at Module.require (module.js:365:17)
I absolutely do not know what to try. There is no npm command I can try. I tried uninstalling and reinstalling Node using homebrew, but this does not work. Please, help
UPDATE
I saw this answer: npm does not work, always get this error -> Error: cannot find module 'are-we-there-yet'
But the solution did not work. I didn’t even have a folder
cd /usr/local/Cellar/node/0.10.22/lib/node_modules
There was no node_modules in the lib folder.
does npm i npm -gn't even work.