4.0.11 • Published 2 years ago

esmall v4.0.11

Weekly downloads
4
License
Apache-2.0
Repository
github
Last release
2 years ago

esmall

a simple minifier for for es+ code

How it works

Just a little wrapper around babili

Using the cli

$ npm install --global esmall
$ esmall input.js // output to stdout
$ esmall input.js -o output.min.js // output to file
$ cat path/to/file.js | esmall > this-works.min.js

API

Basic Usage

var Esmall = require('esmall');
var esmall = new Esmall({
  // put babili options here
});
var minified = esmall.minify('code');

Stream API

var fs = require('fs');

var Esmall = require('esmall');
var esmall = new Esmall({
  // put babili options here
});

fs.createReadStream('path/to/file.js')
  .pipe(esmall)
  .pipe(process.stdout);

This is gross

I know 🎉

TODO

  • allow cli to work with multiple files

License

Apache v2.0

4.0.11

2 years ago

4.0.9

2 years ago

4.0.8

2 years ago

4.0.5

2 years ago

4.0.4

2 years ago

4.0.10

2 years ago

4.0.7

2 years ago

4.0.6

2 years ago

4.0.1

2 years ago

4.0.3

2 years ago

4.0.2

2 years ago

4.0.0

7 years ago

3.2.1

7 years ago

3.2.0

7 years ago

3.1.0

7 years ago

3.0.0

7 years ago

2.0.1

7 years ago

2.0.0

7 years ago

1.2.2

7 years ago

1.2.1

7 years ago

1.2.0

7 years ago

1.1.6

7 years ago

1.1.5

7 years ago

1.1.4

7 years ago

1.1.3

7 years ago

1.1.2

7 years ago

1.1.1

7 years ago

1.1.0

7 years ago