forked from FrDH/mmenu-js
-
Notifications
You must be signed in to change notification settings - Fork 0
/
gulpfile.js
executable file
·69 lines (54 loc) · 1.24 KB
/
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
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
/*
Tasks:
$ gulp : Runs the "js" and "css" tasks.
$ gulp js : Runs the "js" tasks.
$ gulp css : Runs the "css" tasks.
$ gulp watch : Starts a watch on the "js" and "css" tasks.
$ gulp polyfill : Creates the polyfill file.
Flags for the custom task:
--i ../path/to : Create a custom build using "mmenu.module.ts", "_includes.scss" and "_variables.scss" from the specified directory.
--o ../path/to : Sets the "output" directory to the specified directory.
Example:
$ gulp custom --i ../my-custom-input --o ../my-custom-output
$ gulp polyfill --i ../my-custom-input --o ../my-custom-output
*/
const { parallel, series } = require('gulp');
const js = require('./gulp/js');
const css = require('./gulp/css');
const polyfills = require('./gulp/polyfills');
/*
$ gulp
*/
exports.default = cb => {
parallel(js.all, css.all)(cb);
};
/*
$ gulp js
*/
exports.js = cb => {
js.all(cb);
};
/*
$ gulp css
*/
exports.css = cb => {
css.all(cb);
};
/*
$ gulp custom
*/
exports.custom = cb => {
parallel(js.custom, css.custom)(cb);
};
/*
$ gulp watch
*/
exports.watch = cb => {
parallel(series(js.all, js.watch), series(css.all, css.watch))(cb);
};
/*
$ gulp polyfill
*/
exports.polyfill = cb => {
parallel(polyfills)(cb);
};