Skip to content

Commit

Permalink
docs: mention Terser instead of UglifyJS
Browse files Browse the repository at this point in the history
Now that angular#11996 landed, the CLi uses Terser instead of UglifyJS.
  • Loading branch information
cexbrayat committed Oct 30, 2018
1 parent f52f043 commit a2c51b7
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions docs/documentation/build.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,15 +35,15 @@ ng build --base-href /myUrl/
### Bundling & Tree-Shaking

All builds make use of bundling and limited tree-shaking, while `--prod` builds also run limited
dead code elimination via UglifyJS.
dead code elimination via Terser.

### `--build-optimizer` and `--vendor-chunk`

When using Build Optimizer the vendor chunk will be disabled by default.
You can override this with `--vendor-chunk=true`.

Total bundle sizes with Build Optimizer are smaller if there is no separate vendor chunk because
having vendor code in the same chunk as app code makes it possible for Uglify to remove more unused
having vendor code in the same chunk as app code makes it possible for Terser to remove more unused
code.

### CSS resources
Expand All @@ -57,7 +57,7 @@ You'll see these resources be outputted and fingerprinted at the root of `dist/`

To build in ES2015 mode, edit `./tsconfig.json` to use `"target": "es2015"` (instead of `es5`).

This will cause application TypeScript and Uglify be output as ES2015, and third party libraries
This will cause application TypeScript and Terser be output as ES2015, and third party libraries
to be loaded through the `es2015` entry in `package.json` if available.

Be aware that JIT does not support ES2015 and so you should build/serve your app with `--aot`.
Expand Down
2 changes: 1 addition & 1 deletion packages/angular_devkit/build_optimizer/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ Transformations applied depend on file content:
- [Import tslib](#import-tslib): applied when TypeScript helpers are found.

Some of these optimizations add `/*@__PURE__*/` comments.
These are used by [UglifyJS](https://github.com/mishoo/UglifyJS2) to identify pure functions that can potentially be dropped.
These are used by [Terser](https://github.com/terser-js/terser) to identify pure functions that can potentially be dropped.


### Class fold
Expand Down

0 comments on commit a2c51b7

Please sign in to comment.