gulp-eslint-style-checker

Performs code style checking using eslint trough gulp

No longer maintained
Last updated 4 years ago by engvik .
Repository · Bugs · Original npm · Tarball · package.json
$ cnpm install gulp-eslint-style-checker 
SYNC missed versions from official npm registry.

Eslint Style Checker

Build Status Dependencies Status DevDependencies Status npm version Code Climate

Performs code style check by using eslint and gulp (optional)

Code style

We make use of the eslint-config-airbnb package with a few custom rules inspired by this blog post.

Usage

Eslint style checker used by the development team in Scandinavia Online.

Gulp

If you use gulp as a build tool, this package exposes a style-checker function that has two parameters;

  • file-pattern
    The directory to check, in reality the argument is passed straight to gulp.src(file-pattern)
  • config
    If you want to use a custom config, the path to it can be passed as the second parameter.
import { styleCheck } from 'gulp-eslint-style-checker';

gulp.task('style-check', () => {
    return styleCheck('**/*.js', 'optional/path/to/custom/eslintrc.json');
});

if you use this option we expect you to have installed gulp in your application.

Custom config

You can use your own eslint config by either passing the path to it as a second parameter to styleCheck or by passing the path as a command line argument: gulp style-check --config path/to/eslintrc.json.

NPM Script

If you want to skip gulp and just use eslint directly that is also possible by adding this to your package.json file

"scripts": {
    "style-check": "./node_modules/gulp-eslint-style-checker/node_modules/.bin/eslint -c ./node_modules/gulp-eslint-style-checker/eslintrc.json **/*.js"
}

then this can be executed by running npm run style-check. This is not dependent on any packages

Current Tags

  • 4.0.1                                ...           latest (4 years ago)
  • 2.0.4                                ...           v2.0.4 (5 years ago)

10 Versions

  • 4.0.1 [deprecated]           ...           4 years ago
  • 4.0.0 [deprecated]           ...           4 years ago
  • 3.1.1 [deprecated]           ...           5 years ago
  • 3.0.2 [deprecated]           ...           5 years ago
  • 3.0.0 [deprecated]           ...           5 years ago
  • 2.0.5 [deprecated]           ...           5 years ago
  • 2.0.4 [deprecated]           ...           5 years ago
  • 2.0.3 [deprecated]           ...           5 years ago
  • 2.0.2 [deprecated]           ...           5 years ago
  • 2.0.1 [deprecated]           ...           5 years ago
Downloads
Today 0
This Week 0
This Month 0
Last Day 0
Last Week 0
Last Month 0
Dependencies (7)
Dev Dependencies (1)

Copyright 2014 - 2016 © taobao.org |