Skip to content
This repository has been archived by the owner on May 11, 2018. It is now read-only.

Commit

Permalink
Update README
Browse files Browse the repository at this point in the history
  • Loading branch information
existentialism committed Apr 10, 2017
1 parent 3710db5 commit 5692c83
Showing 1 changed file with 10 additions and 10 deletions.
20 changes: 10 additions & 10 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -120,16 +120,6 @@ A query to select browsers (ex: last 2 versions, > 5%) using [browserslist](http

Note, browsers' results are overridden by explicit items from `targets`.

### `targets.uglify`

`number | true`

UglifyJS does not currently support any ES6 syntax, so if you are using Uglify to minify your code, targeting later browsers may cause Uglify to throw syntax errors.

To prevent these errors - specify the uglify option, which will enable all plugins and, as a result, fully compile your code to ES5. However, the `useBuiltIns` option will still work as before, and only include the polyfills that your target(s) need.

> NOTE: Uglify has a work-in-progress "Harmony" branch to address the lack of ES6 support, but it is not yet stable. You can follow its progress in [UglifyJS2 issue #448](https://github.com/mishoo/UglifyJS2/issues/448). If you require an alternative minifier which _does_ support ES6 syntax, we recommend using [Babili](https://github.com/babel/babili).
### `loose`

`boolean`, defaults to `false`.
Expand Down Expand Up @@ -245,6 +235,16 @@ import "babel-polyfill/core-js/modules/es7.string.pad-end";

Don't add polyfills automatically per file, or transform `import "babel-polyfill"` to individual polyfills.

### `useSyntax`

`boolean`, defaults to `true`.

NOTE: `targets.uglify` is deprecated and will be removed in the next major in favor of this.

Runs the transforms needed for the targeted environment(s). Set this to `false` if you want to force running _all_ transforms which is useful if the output will be run through UglifyJS, or an environment that only supports ES5.

> NOTE: Uglify has a work-in-progress "Harmony" branch to address the lack of ES6 support, but it is not yet stable. You can follow its progress in [UglifyJS2 issue #448](https://github.com/mishoo/UglifyJS2/issues/448). If you require an alternative minifier which _does_ support ES6 syntax, we recommend using [Babili](https://github.com/babel/babili).
---

## Examples
Expand Down

0 comments on commit 5692c83

Please sign in to comment.