npm install throws "integrity checksum failed when using sha1: wanted sha1-6G...= but got sha512..." error

Solution 1:

Delete node_modules folder. Use rimraf to delete the folder faster:

npm install rimraf -g
rimraf node_modules

Then do

 npm install

Make sure that you close VS Code application. Sometimes it will cause errors if the folder is open in any application.