eslint-config-actum
is a set of rules for gulp-eslint plugin, which is heavily based on [AirBnB JavaScript Styleguide](airbnb javascript style guide).
To use this configuration in your project, follow these steps:
npm install -D actum/eslint-config-actum
"eslintConfig": {
"extends": "actum"
}
In order to use different rules depending on the environment, include the configuration module in your Gulp task and use it as follows:
/* This is environment example */
const environment = {
isDevelopment: true
};
/* Get configuration file depending on the environment */
const eslintConfig = require('eslint-config-actum').getConfig({ environment });
...
gulp.task('lint', () => {
const options = { configName: eslintConfig };
return gulp.src(...)
.pipe(eslint(options))
.pipe(eslint.format());
});