yarn npm 设置淘宝镜像

yarn npm 设置淘宝镜像

npm 设置淘宝镜像

npm config set registry https://registry.npmmirror.com

yarn 设置淘宝镜像

yarn config set registry https://registry.npmmirror.com

常用淘宝镜像

npm

npm config set disturl https://npmmirror.com/dist
npm config set electron_mirror https://npmmirror.com/mirrors/electron/
npm config set sass_binary_site https://npmmirror.com/mirrors/node-sass/
npm config set phantomjs_cdnurl https://npmmirror.com/mirrors/phantomj/

yarn

yarn config set disturl https://npmmirror.com/dist -g
yarn config set electron_mirror https://npmmirror.com/mirrors/electron/ -g
yarn config set sass_binary_site https://npmmirror.com/mirrors/node-sass/ -g
yarn config set phantomjs_cdnurl https://npmmirror.com/mirrors/phantomj/ -g