Installations
npm install jarvis-es5
Developer Guide
Typescript
No
Module System
CommonJS
Node Version
6.4.0
NPM Version
3.10.3
Score
32.1
Supply Chain
70.9
Quality
63.4
Maintenance
25
Vulnerability
85
License
Releases
Unable to fetch releases
validate.email 🚀
Verify real, reachable, and deliverable emails with instant MX records, SMTP checks, and disposable email detection.
Download Statistics
Total Downloads
1,053
Last Day
1
Last Week
3
Last Month
14
Last Year
65
Bundle Size
1.06 MB
Minified
286.07 kB
Minified + Gzipped
Package Meta Information
Latest Version
1.1.0
Package Id
jarvis-es5@1.1.0
Size
31.53 kB
NPM Version
3.10.3
Node Version
6.4.0
Total Downloads
Cumulative downloads
Total Downloads
1,053
Last Day
0%
1
Compared to previous day
Last Week
200%
3
Compared to previous week
Last Month
133.3%
14
Compared to previous month
Last Year
-23.5%
65
Compared to previous year
Daily Downloads
Weekly Downloads
Monthly Downloads
Yearly Downloads
jarvis-js
Complete gulp task for compiling js, with help of webpack.
Installation
npm i --save-dev jarvis-es5
Usage
I tried to do usage of this task as simple as posible. The following example will compile all the *.entry.js files under the folder src/ into to destination folder dist/, and rename it all from *.entry.js to *.bundle.js
1const gulp = require('gulp'); 2var js = require('./index'); 3 4var jsConfig = { 5 entry: 'test/src/**/*.entry.js', 6 output: 'test/dist/js/', 7 webpack: require('./test/webpack.config.js') 8}; 9 10gulp.task('js:build', (done) => { 11 jsConfig.webpack.watch = false; 12 return js.run(jsConfig)(done); 13}); 14 15gulp.task('js:watch', (done) => { 16 jsConfig.webpack.watch = true; 17 return js.run(jsConfig)(done); 18});
So we had the folowing file tree:
src/
main.entry.js
common.entry.js
after running less:build (or less:watch if you want to watching changes), we will have:
src/
main.entry.js
common.entry.js
dist/
main.bundle.js
common.bundle.js
Webpack
As you can see, I use webpack for bundling js, it means you can use all power of webpack.config.js (except entry and output options).
Jarvis
But the killer-feature of this task is gulp-jarvis. With help of this plugin we can easily redeclare the destination folder by adding a special comment file to the beginning of the entry file. So let's go back to the previous example:
src/
main.entry.js
common.entry.js
Lets change the contents of the file style.entry.less a little bit. We will add the following line to the beginning of style.entry.less
/*file-output:dist/js/main.js;*/
And after this ша run less:build again at the output we will have:
src/
main.entry.less
common.entry.less
dist/
common.bundle.css
style/
main.js
See, its so easy.
Options
The API of the package has only one method:
js.build(options)
1defaultOptions = { 2 entry: `src/**/*.entry.js`, // source glob for gulp.src(...) 3 output: 'dist/js/', //default destination folder 4 webpack: undefined, //webpack config 5}

No vulnerabilities found.

No security vulnerabilities found.