Build scripts for Lighting Beetle* light framework.
node.js >= 6.9.0
npm install light-scripts --save-dev
or
yarn add light-scripts --dev
- Webserver with liverelaod (Browsersync)
- Pug templates compilation with incremental builds (Pug) (pug-inheritance)
- Scss compilation (node-sass)
- CSS autoprefixing (autoprefixer)
- JS bundling (webpack 2)
- JS compilation (babel) (babel-preset-env)
- JS linting (eslint) (airbnb-base)
- Image optimization (imagemin)
- Lean Modernizr builds (gulp-modernizr)
- Deploying via rsync/sftp (gulp-rsync)
Add light.config.js
file to light
project root. Format of config file should look like this:
module.exports = (defaultPaths, defaultConfig, flags) => ({
paths: {},
config: {},
});
Via config file, default configuration can be customized if necessary.
If custom configuration is not needed, light.config.js
can be omitted.
Tasks should be run in main project folder, which depends on light-scripts
.
Main gulp tasks:
- Project serving with live-reload:
gulp serve
- Project build:
gulp serve
- Other tasks:
gulp -T
MIT