1.安装yarn
npm install -g yarn --registry=https://registry.npm.taobao.org
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 config set prefix "D:Program Files
odejs
ode-global"
yarn config set cache "D:Program Files
odejs
ode-cache"
2.安装react
yarn add react
yarn remove react
yarn add react --dev
yarn upgrade
------
npm install react
npm uninstall react
npm install react --save-dev
npm update
3.安装create-react-app
yarn add create-react-app -g
create-react-app my-app
--
npm install -g create-react-app