Fix the document of keep_fnames option
This commit is contained in:
committed by
Richard van Velzen
parent
af37ecafe1
commit
9edbe93df5
@@ -378,8 +378,8 @@ to set `true`; it's effectively a shortcut for `foo=true`).
|
|||||||
for code which relies on `Function.length`.
|
for code which relies on `Function.length`.
|
||||||
|
|
||||||
- `keep_fnames` -- default `false`. Pass `true` to prevent the
|
- `keep_fnames` -- default `false`. Pass `true` to prevent the
|
||||||
compressor from mangling/discarding function names. Useful for code relying on
|
compressor from discarding function names. Useful for code relying on
|
||||||
`Function.prototype.name`.
|
`Function.prototype.name`. See also: the `keep_fnames` [mangle option](#mangle).
|
||||||
|
|
||||||
- `passes` -- default `1`. Number of times to run compress. Use an
|
- `passes` -- default `1`. Number of times to run compress. Use an
|
||||||
integer argument larger than 1 to further reduce code size in some cases.
|
integer argument larger than 1 to further reduce code size in some cases.
|
||||||
@@ -715,6 +715,10 @@ Other options:
|
|||||||
- `eval` — mangle names visible in scopes where eval or with are used
|
- `eval` — mangle names visible in scopes where eval or with are used
|
||||||
(disabled by default).
|
(disabled by default).
|
||||||
|
|
||||||
|
- `keep_fnames` -- default `false`. Pass `true` to not mangle
|
||||||
|
function names. Useful for code relying on `Function.prototype.name`.
|
||||||
|
See also: the `keep_fnames` [compress option](#compressor-options).
|
||||||
|
|
||||||
Examples:
|
Examples:
|
||||||
|
|
||||||
```javascript
|
```javascript
|
||||||
|
|||||||
Reference in New Issue
Block a user