现在安装 react 脚手架的有三种,
react-boilerplate
react-redux-starter-kit
create-react-app(国内主要运用这一种)
1==>npm install -g create-react-app 全局安装脚手架命令(第一次安装后就不需要在重新安装了)
2==> create-react-app (my-app 创建项目)
若是在第二步过程中出现了 A template was not provided. This is likely because you're using an outdated version of create-react,
执行
npm uninstall -g create-react-app(删除)
然后重新执行 npm install -g create-react-app
等它下载好了之后,启动项目就可以了