Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
gulp.task('lint', () => {
return (
gulp
.src('src/*.js')
// default: use local linting config
.pipe(eslint())
// format ESLint results and print them to the console
.pipe(eslint.format())
.pipe(eslint.failAfterError())
);
});
gulp.task('eslint', () => {
return gulp.src(config.PATHS.src.js)
.pipe(eslint({
rulePaths: [path.join(__dirname, '../../')]
}))
.pipe(eslint.format())
.pipe(eslint.failAfterError());
});
gulp.task('lint', ['build:js'], function () {
return gulp.src(['src/rollup/**/*.js', 'gulpfile.js', 'test/**/*.js', 'docs/docs/examples/**/*.js'])
.pipe(eslint())
.pipe(eslint.format())
.pipe(eslint.failAfterError());
});
gulp.task('lint', function () {
return gulp.src('./' + pkg.main)
.pipe(eslint())
.pipe(eslint.format())
.pipe(eslint.failAfterError());
});
function lint() {
return gulp.src(options.lintPaths)
.pipe(eslint())
.pipe(eslint.formatEach())
.pipe(eslint.failAfterError());
}
function lint() {
return src(['*.js', 'src/*.js', 'src/**/*.js'])
.pipe(eslint())
.pipe(eslint.format())
.pipe(eslint.failAfterError())
}
module.exports = exports = function lint() {
return gulp.src(files)
.pipe(eslint())
.pipe(eslint.format())
.pipe(eslint.failAfterError())
}
function lint () {
return gulp
.src('./src/js/**/*.js')
.pipe(eslint())
.pipe(eslint.format())
.pipe(eslint.failAfterError())
}
function lint(options) {
options = options || { exit: true };
return gulp
.src(PATH.scripts)
.pipe(eslint())
.pipe(eslint.format())
.pipe(options.exit ? eslint.failAfterError() : gutil.noop());
}