Yarn 淘宝源
yarn config set registry https://registry.npm.taobao.org -g
yarn config set sass_binary_site http://cdn.npm.taobao.org/dist/node-sass -g
初始化一个新的项目
yarn init
添加一个依赖包
yarn add [package]
yarn add [package]@[version]
yarn add [package]@[tag]
更新一个依赖包
yarn upgrade [package]
yarn upgrade [package]@[version]
yarn upgrade [package]@[tag]
删除一个依赖包
yarn remove [package]
安装所有的依赖包
yarn or yarn install
列出每个缓存的包
yarn cache ls
清除本地缓存
yarn cache clean