现在vue-cli基本上用yarn安装工具包,如果总是安装慢,看你是不是设置了代理,我设置走代理不知道哪一步出问题,一直提示我网络有问题,然而我这边看着youtube还是一点问题都没,贼奇怪。
首先,删除代理

yarn config remove proxy
npm config remove https-proxy

给yarn设置淘宝源

yarn config set registry http://registry.npm.taobao.org/

给node-sass设置淘宝源,这玩意每次都难装

yarn config set sass-binary-site http://npm.taobao.org/mirrors/node-sass

大功告成,创建一个项目10秒不到

Last modification:November 28, 2020
If you think my article is useful to you, please feel free to appreciate