generator-react-rocket
v1.0.0
Published
Yeoman generator to bootstrap a Flux/React web app with Gulp
Downloads
7
Maintainers
Readme
generator-react-rocket
A Yeoman generator to bootstrap a React/Flux application powered by Gulp! 🚀
Features
- Flux directory structure
- Build with Gulp
- Compile React (JSX) components (with Babel)
- Handle CommonJS dependencies with Webpack
- ES6 to ES5 (with Babel)
- Lint JS and JSX code with JSHint
- Compile sass stylesheets
- Browser sync
- Uglify javascript with UglifyJS
- Minify css with gulp-minify-css
- Build for Production with
--production
- Preprocess javascript with gulp-preprocess
- Components testing with Karma
- Component sub-generator
Getting Started
Install
npm install -g yo
npm install -g generator-react-rocket
Usage
mkdir myapp && cd myapp
yo react-rocket
Run your tests (with Karma)
npm test
Gulp tasks
gulp
orgulp serve
to start a developement web server with live reload (supports the--production
flag)gulp build
to build the app in dist/ directory (supports the--production
flag)gulp clean
to clean up dist/ directory
react-rocket:component
Generates a JSX component class in src/scripts/components
and the associated test file in src/scripts/components/__tests__
yo react-rocket:component
Future improvements
- More sub-generators for commonly created files
- Remove npm dependencies and use bower components instead
- Create a gulp task to run tests
See also
Rocket, a Rails API application template.
License
MIT