下载
https://nodejs.org/en/
安装
打开安装文件,按指示安装即可。
配置
prefix
npm config set prefix "D:\TOOLS\Node.js\install_file\node_global"
缓存
npm config set cache "D:\TOOLS\Node.js\install_file\node_cache"
配置镜像站
npm config set registry=http://registry.npm.taobao.org
查看配置
npm config list
查看是仓库是否可用
npm info vue
配置代理
npm config set proxy http://username:password@server:port
npm confit set https-proxy http://username:password@server:port
再次 npm info vue 正常
升级npm
npm install npm -g
配置不环境变量
配置NODE_PATH
(注意,操作需要重新打开CMD让上面的环境变量生效)
nodesjs创建vue项目
## 参考
https://www.cnblogs.com/lgx5/p/10732016.html