An open API service indexing awesome lists of open source software.

https://github.com/rodeymanager/gulp-jsminer

js miner
https://github.com/rodeymanager/gulp-jsminer

gulp javascript jsminer node

Last synced: 3 months ago
JSON representation

js miner

Awesome Lists containing this project

README

          

### gulp-jsminer (javascript 压缩)

```javascript
const jsminer = require('gulp-jsminer');

gulp.task('default', () => {
gulp
.src('assets/js/**/*')
.pipe(jsminer({ toplevel: true }))
.pipe(gulp.dest('dist'));
});
```

```javascript
// 转换ES6+后进行压缩
const babel = require('gulp-babel');
const jsminer = require('gulp-jsminer');

gulp.task('default', () => {
gulp
.src('assets/js/**/*')
.pipe(babel())
.pipe(jsminer())
.pipe(gulp.dest('dist'));
});
```

## options

see [terser](https://github.com/terser/terser#command-line-options) options

### Listen

ISC