A react/redux/webpack boilerplate application with scaffolding, styleguide, and tests
Clone the repo
$ git clone https://github.com/miketownsend/neverbland-tvmaze.git
$ cd neverbland-tvmaze
Then, install the dependencies
$ npm install
Serve the web application with webpack using:
$ npm start
// Run unit tests using Jest
$ npm test
// Run end to end tests using Cypress
& npm run integration_tests
// Run the build here
npm run build
// View the distribution build at http://localhost:3002 using:
npm run build:serve
Generate a style guide using Styleguidist.
Run the styleguide dev server (watches component library)
& npm run styleguide
View the styleguide in the browser
Build the styleguide once (for CI)
$ npm run styleguide:build
The scaffolding is a simple + messy node script that is next on my list for improvement. Blueprints of common patterns are provided for:
- component (component / styles / styleguide)
- container (container / styles)
- module (actions / constants / reducer / saga / selectors / tests)
- model (mock / transforms / test)
- route -- coming soon
- form -- coming soon
These can be generated from the command line using:
// Generate a new component/module/route
$ node blueprint <type> <name> --overwrite
// e.g.
$ node blueprint module ActivityScreen -o
$ node blueprint component UserIcon
$ node blueprint model schedule
// If you remove a generated module/component/route
// You can reset the sagas/routers/styles using...
$ node blueprint reset
- Fix tests a. jest --watch a. Add saga tests for /module/request
- Improve scaffolding:
- Move scaffolding to use simple text replacement instead of preprocessor
- Add route scaffolding
- Add form scaffolding (deploy simple redux-form and form-container)
- Move to JSS
- Typescript (?)
- Add base authentication module
- Add base websocket module (start connection, receive RxJS observer)
- Add to component library (find good 3rd party tools) a. Basic form components a. Rich autocomplete a. Menu + Navigation a. Loading states