# gulp-uglify-es

> gulp stream to uglify with 'terser' (es6 supported).

Latest version **3.0.0** (published 2021-07-26) · MIT license · 0 weekly downloads

## Install

```sh
npm install gulp-uglify-es
pnpm add gulp-uglify-es
yarn add gulp-uglify-es
bun add gulp-uglify-es
```

## Health

**Score 25/100 (F)** — status: abandoned.

Positive: has types; no vulnerabilities; high quality score.

Warnings: low downloads; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 3.0.0 |
| Published | 2021-07-26 |
| First published | 2017-07-25 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | CommonJS |
| Dependencies | 5 |
| Unpacked size | 10.3 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | Itay Ronen |
| Maintainers | itayronen |
| Keywords | minify, uglify, uglify-es, uglify-es6, terser, es, es6, gulp, gulpplugin |

## Links

- npm: https://www.npmjs.com/package/gulp-uglify-es
- Repository: https://gitlab.com/itayronen/gulp-uglify-es
- Issues: https://gitlab.com/itayronen/gulp-uglify-es/issues
- npm.io page: https://npm.io/package/gulp-uglify-es

## Dependencies (5)

- [vinyl](https://npm.io/package/vinyl.md) ^2.2.1
- [terser](https://npm.io/package/terser.md) ^5.7.1
- [o-stream](https://npm.io/package/o-stream.md) ^0.3.0
- [plugin-error](https://npm.io/package/plugin-error.md) ^1.0.1
- [vinyl-sourcemaps-apply](https://npm.io/package/vinyl-sourcemaps-apply.md) ^0.2.1

## Alternatives

- [duck](https://npm.io/package/duck.md) — 4.2M weekly downloads
- [ava](https://npm.io/package/ava.md) — 560.2K weekly downloads
- [storybook-addon-module-mock](https://npm.io/package/storybook-addon-module-mock.md) — 71.7K weekly downloads
- [vest](https://npm.io/package/vest.md) — 50.1K weekly downloads
- [@ethereum-waffle/mock-contract](https://npm.io/package/@ethereum-waffle/mock-contract.md) — 40.0K weekly downloads

## Recent versions

- 3.0.0 (latest) — 2021-07-26
- 2.0.0 — 2019-10-18
- 1.0.4 — 2018-05-18
- 1.0.3 — 2018-05-18
- 1.0.2 — 2018-05-18
- 1.0.1 — 2018-02-17
- 1.0.0 — 2018-01-15
- 0.2.0 — 2018-01-10
- 0.1.11 — 2018-01-08
- 0.1.10 — 2018-01-08
- 0.1.9 — 2017-12-13
- 0.1.8 — 2017-12-07
- 0.1.7 — 2017-12-01
- 0.1.6 — 2017-11-24
- 0.1.5 — 2017-11-24
- … 5 more at https://npm.io/package/gulp-uglify-es/versions

## README

# gulp-uglify-es
gulp stream to uglify with 'terser' (es6 supported).

terser is the new 'uglify-es'. uglify-es is no longer maintained.

## Install
npm install --save-dev gulp-uglify-es

## Usage
gulpfile.js
```js
let gulp = require("gulp");
let rename = require("gulp-rename");
let uglify = require('gulp-uglify-es').default;

gulp.task("uglify", function () {
	return gulp.src("lib/bundle.js")
		.pipe(rename("bundle.min.js"))
		.pipe(uglify(/* options */))
		.pipe(gulp.dest("lib/"));
});
```
For documentation about the options-object, See the [Uglify API Reference](https://www.npmjs.com/package/terser#api-reference).

## Source maps
To generate source maps, use [gulp-sourcemaps](https://www.npmjs.com/package/gulp-sourcemaps).  
Example:  
```js
let gulp = require("gulp");
let rename = require("gulp-rename");
var sourcemaps = require('gulp-sourcemaps');
let uglify = require('gulp-uglify-es').default;

gulp.task("uglify", function () {
	return gulp.src("lib/bundle.js")
		.pipe(rename("bundle.min.js"))
		.pipe(sourcemaps.init())
		.pipe(uglify())
		.pipe(sourcemaps.write()) // Inline source maps.
		// For external source map file:
		//.pipe(sourcemaps.write("./maps")) // In this case: lib/maps/bundle.min.js.map
		.pipe(gulp.dest("lib/"));
});
```

---
_Source: https://npm.io/package/gulp-uglify-es · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
