- Root
- src (source)
- actions
- components
- pages
- containers
- constants
- reducers
- store
- index.js
- style
- webpack.config.js
- server.js
- index.html
- src (source)
npm install --save react react-dom redux react-redux
npm install -g webpack
npm install --save-dev webpack webpack-dev-server
- babel-core
npm install --save-dev babel-core
npm install --save-dev babel-loader babel-preset-es2015 babel-preset-react
npm i --save babel-polyfill
- 在src的index.js添加:
import 'babel-polyfill'
npm install --save-dev css-loader style-loader
npm install --save-dev redux-devtools redux-devtools-dock-monitor redux-devtools-log-monitor
- create
devTools.js
- add in root.js
npm install --save-dev react-hot-loader
npm i --save redux-router
npm i --save react-router
- index.js
- root.dev.js root.prod.js
- configureStore.js
- configureStore.dev.js
- configureStore.prod.js