-
-
Notifications
You must be signed in to change notification settings - Fork 0
/
gulpfile.js
33 lines (28 loc) · 908 Bytes
/
gulpfile.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
'use strict';
const gulp = require('gulp');
const gulpEslint = require('gulp-eslint-new');
const gulpHtmllint = require('gulp-htmllint');
const gulpStylelint = require('gulp-stylelint');
const jsdoc = require('gulp-jsdoc3');
gulp.task('lint-html', () => gulp.src(['./src/html/*.html'])
.pipe(gulpHtmllint({ config : '.htmllintrc.json' }))
);
gulp.task('lint-js', () => gulp.src(['gulpfile.js', './src/js/**/*.js'])
.pipe(gulpEslint({ overrideConfigFile : '.eslintrc.json' }))
.pipe(gulpEslint.format())
);
gulp.task('lint-css', () => gulp.src(['./src/css/*.css'])
.pipe(gulpStylelint({
failAfterError : false,
reporters : [
{
formatter : 'string',
console : true
}
]
}))
);
const jsdocsConfig = require('./jsdoc.json');
gulp.task('docs', () => gulp.src(['CHANGELOG.md', 'README.md', './src/js/*/*.js'], { read : false })
.pipe(jsdoc(jsdocsConfig))
);