Mean Stack application module.js:471 throw err; ^

615 Views Asked by At

Getting Following error message,I tried to fix by updating npm and reinstall of mean stack application by running npm install

Error: Cannot find module 'npm'
    at Function.Module._resolveFilename (module.js:469:15)   
    at Function.Module._load (module.js:417:25)  
    at Module.require (module.js:497:17)  
    at require (internal/module.js:20:19)  
    at Object.<anonymous>  
    (C:\Users\Laptop2\AppData\Roaming\npm\node_modules\mean-cli\lib\cli.js:5:7)  
    at Module._compile (module.js:570:32)  
    at Object.Module._extensions..js (module.js:579:10)  
    at Module.load (module.js:487:32)  
    at tryModuleLoad (module.js:446:12)  
    at Function.Module._load (module.js:438:3)  
2

There are 2 best solutions below

0
Harish On

Update Npm by using following command issue resolve

npm install npm@latest -g
0
Yogesh On

Try: npm install npm@latest -g