React + Redux + React Router + React Impression + Webpack 3
First, install Yeoman and generator-react-impression:
npm i -g yo generator-react-impression
Then generate your new project:
yo react-impression
OR upgrade existed project:
cd YOUR_PROJECT_FOLDER
yo react-impression --upgrade
First, run following command in your project folder:
npm start
Then, open your browser with http://localhost:8080.
First, add your Qiniu key to package.json
:
{
"deploy": {
"ACCESS_KEY": "",
"SECRET_KEY": ""
}
}
Then run following command to release patch
version:
npm version patch -m 'Release version %s'
OR release minor
version:
npm version minor -m 'Release version %s'
-
Proxy API request
First, update proxy table in
package.json
. For example:{ "proxy": { "/api": { "target": "http://localhost:3000", "changeOrigin": true } } }
Then restart development server:
npm start
-
Create Flux Standard Action with redux-actions
-
Follow standard of ducks-modular-redux
-
Update state using dot-prop-immutable
-
Write styles with babel-plugin-react-css-modules
MIT