npm ERR! Unexpected token } in JSON at position 438325
Error :
npm ERR! Unexpected token } in JSON at position 438325
when trying to run "npm install" command in angular CLI getting the below error:
npm ERR! Unexpected token } in JSON at position 438325
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\Subba\AppData\Roaming\npm-cache\_logs\2019-04-23T13_44_36_571Z-debug.log
To resolve this error below are the solutions
Solutions:
- execute the command "npm cache verify" - which will clear the cache of package.json then re run the "npm install" it will work.
- If still not working go to manually located angular root folder and delete the "package.json.lock" then re run the "npm install" command.
- still if you are facing the issue it may be due to proxy settings because when delete the "package.json.lock" it will delete the existing saved proxy settings so re run the proxy setup commands.
npm config set proxy <<PROXY_NAME>> - suppose dont want to set proxy the run the below command:
npm config set strict-ssl false
Comments
Post a Comment