Check the node installation stiffness

// cmd
where node 
Copy the code

Check whether the installation is successful

node -v
Copy the code

The default package.json generated

npm init -y
Copy the code

Clear the cache

npm cache clean -f
Copy the code

Look at mirror

npm config get registry
Copy the code

Set mirror (Taobao)

npm config set registry https://registry.npm.taobao.org
Copy the code

The node to upgrade

node stable
Copy the code

View the installed modules

npm list
Copy the code

Delete node_modules

// NPM install rimraf -g rimraf node_modules // NPM uninstallCopy the code