a magical boilerplate with hot reloading and awesome error handling™ that uses webpack, redux, react and redux-undo
You need to have npm
installed (it comes with node.js).
npm install
During development, run:
npm run dev
Which enables some development tools.
In production, run:
npm start
These commands (unless configured otherwise) start a web server at: http://localhost:3000
Save the file in your editor and immediately see the changes reflected in your browser - coding has never been more efficient. What a beautiful world we live in nowadays.
Many of us know this: You accidentally type in the wrong window once, add a
random character to your code and when you run it again you're like "WTF this
just worked?!" - let webpack-hot-middleware
help you out with this:
Mutating the state directly causes lots of bugs with Redux. There are no immutables in JavaScript, so we can't make sure this doesn't happen unless we use something like Immutable.js.
If you run this boilerplate in dev mode (npm run dev
), it will tell you when
you mutate something directly:
npm test
Special thanks to these awesome projects/people making this possible ❤️
- React
- Redux
- Babel - for ES6 support
- redux-boilerplate by chentsulin - this boilerplate is based off his project
- babel-plugin-react-transform by gaearon - as a base for the hot reloading and error handling
- react-transform-catch-errors by gaearon - error handling
- react-transform-hmr by gaearon - hot reloading
- redux-devtools by gaearon
- redux-immutable-state-invariant by leoasis - detect state mutations
redux-boilerplate: MIT © C.T. Lin
redux-undo-boilerplate: MIT © Daniel Bugl