From eae26756f1419e7e601bae8b44d69f4e80dd0d61 Mon Sep 17 00:00:00 2001 From: "Alex Lam S.L" Date: Fri, 19 May 2017 09:06:29 +0800 Subject: introduce `unsafe_regexp` (#1970) fixes #1964 --- README.md | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) (limited to 'README.md') diff --git a/README.md b/README.md index a2997b7f..a7635095 100644 --- a/README.md +++ b/README.md @@ -462,6 +462,9 @@ If you're using the `X-SourceMap` header instead, you can just omit `sourceMap.u - `unsafe_proto` (default: false) -- optimize expressions like `Array.prototype.slice.call(a)` into `[].slice.call(a)` +- `unsafe_regexp` (default: false) -- enable substitutions of variables with + `RegExp` values the same way as if they are constants. + - `conditionals` -- apply optimizations for `if`-s and conditional expressions @@ -552,10 +555,10 @@ If you're using the `X-SourceMap` header instead, you can just omit `sourceMap.u - `keep_infinity` -- default `false`. Pass `true` to prevent `Infinity` from being compressed into `1/0`, which may cause performance issues on Chrome. -- `side_effects` -- default `true`. Pass `false` to disable potentially dropping -functions marked as "pure". A function call is marked as "pure" if a comment -annotation `/*@__PURE__*/` or `/*#__PURE__*/` immediately precedes the call. For -example: `/*@__PURE__*/foo()`; +- `side_effects` -- default `true`. Pass `false` to disable potentially dropping + functions marked as "pure". A function call is marked as "pure" if a comment + annotation `/*@__PURE__*/` or `/*#__PURE__*/` immediately precedes the call. For + example: `/*@__PURE__*/foo();` ## Mangle options -- cgit v1.2.3