slush-web-app
v1.1.0
Published
Scaffold a web app with Slush
Downloads
3
Maintainers
Readme
slush-web-app
Scaffold a web app with Slush
Install
- Install
gulp.js
- Install Slush
- Install the
slush-web-app
generator
$ npm install -g gulp slush slush-node-module
Usage
Create a new folder for your project and cd
into it:
$ mkdir my-new-project && cd my-new-project
Run the generator and answer the questions.
$ slush web-app
? Project name: my-new-project
? What tools are you going to use? (Press <space> to select)
❯◯ React
◯ React Router
◯ Redux
Features
This generator will create a modern and clean structure so you can start working on your application without worrying about the setup.
It uses a simple task management system via npm
scripts.
Overview
- ES2015 syntax support with a few experimental features (such as ES7 function bind)
- Uses
browserify
with thebabelify
transformer to do the JavaScript transpiling - Support for the latest CSS syntax via
cssnext
- Support file watching thanks to
watchy
- Uses
xo
for dead simple JavaScript linting - Automatic browser reloading using
live-server
(servespublic
on port8080
) - Simple folder structure split in
public
(path to be served) andsource
(actual source files)
Tasks
build
– Build JavaScript and CSS files (both run in parallel)build:js
– Build JavaScript filesbuild:css
– Build CSS fileswatch
– Watch for JavaScript and CSS file changes (both run in parallel)watch:js
– Watch for JavaScript file changeswatch:css
– Watch for CSS file changesstart
– Startup static serverlint
– Lint JavaScript files
Tools
Opt-in tools that you can add to your project.
React
Enable React support on the project. Changes transpiling and linting settings and scaffolds a components
folder with a simple application component.
Redux
Enable Redux support on the project. Will listen for a store and then re-render the application component on changes.
React Router
Enable React Router support on the project. Will listen for the /
route and then re-render the application component on route matching.
TODO
- [ ] Add simple Redux bootstrap
- [ ] Add simple React Router bootstrap
License
MIT © Rafael Rinaldi