# esbuild-webpack-plugin

> Use esbuild as minifier.

Latest version **1.1.0** (published 2020-10-19) · MIT license · 0 weekly downloads

## Install

```sh
npm install esbuild-webpack-plugin
pnpm add esbuild-webpack-plugin
yarn add esbuild-webpack-plugin
bun add esbuild-webpack-plugin
```

## 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 | 1.1.0 |
| Published | 2020-10-19 |
| First published | 2020-05-07 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | CommonJS |
| Dependencies | 1 |
| Unpacked size | 10.5 KB |
| Known vulnerabilities | 0 (+1 in 1 direct dependencies) |
| Install scripts | no |
| Author | chencheng |
| Maintainers | sorrycc |

## Links

- npm: https://www.npmjs.com/package/esbuild-webpack-plugin
- npm.io page: https://npm.io/package/esbuild-webpack-plugin

## Dependencies (1)

- [esbuild](https://npm.io/package/esbuild.md) ^0.7.15

## Recent versions

- 1.1.0 (latest) — 2020-10-19
- 1.0.5 — 2020-07-29
- 1.0.4 — 2020-07-27
- 1.0.3 — 2020-07-14
- 1.0.2 — 2020-07-08
- 1.0.0 — 2020-05-27
- 1.0.0-beta.5 — 2020-05-27
- 1.0.0-beta.4 — 2020-05-14
- 1.0.0-beta.3 — 2020-05-07

## README

# esbuild-webpack-plugin

Use [esbuild](https://github.com/evanw/esbuild) as minifier for webpack.

## Why is this package?

[彻底告别编译 OOM，用 esbuild 做压缩器](https://zhuanlan.zhihu.com/p/139219361)。

## Install

```bash
$ yarn add esbuild-webpack-plugin --dev
```

## Webpack config

```js
const ESBuildPlugin = require('esbuild-webpack-plugin').default;

module.exports = {
  optimization: {
    minimizer: [
      new ESBuildPlugin(),
      /**
       * Or customize ESBuild options like below:
       *
       * new ESBuildPlugin({target: "es5"}),
       *
       * For details, please refer: https://github.com/evanw/esbuild
       */
    ],
  },
};
```

## Test

```shell script
# Get prepared
$ yarn && yarn build

# Minify with terser
$ yarn build:example

# Minify with esbuild
$ yarn build:example:esbuild

# Do not minify
$ yarn build:example:nocompress
```

## LICENSE

MIT

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