You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Turn on or off mangling with default options. If an `Object` is specified, it is passed directly to `ast.mangle_names()`*and*`ast.compute_char_frequency()` (mimicking command line behavior). [View all options here](https://github.com/mishoo/UglifyJS2#mangler-options).
58
58
59
59
#### compress
60
-
Type: `Boolean``Object`
60
+
Type: `Boolean``Object`
61
61
Default: `{}`
62
62
63
63
Turn on or off source compression with default options. If an `Object` is specified, it is passed as options to `UglifyJS.Compressor()`. [View all options here](https://github.com/mishoo/UglifyJS2#compressor-options).
64
64
65
65
#### beautify
66
-
Type: `Boolean``Object`
66
+
Type: `Boolean``Object`
67
67
Default: `false`
68
68
69
69
Turns on beautification of the generated source code. [View all options here](https://github.com/mishoo/UglifyJS2#beautifier-options)
70
70
71
71
###### parse.expression
72
-
Type: `Boolean`
72
+
Type: `Boolean`
73
73
Default: `false`
74
74
75
75
Parse a single expression, rather than a program (for parsing JSON)
76
76
77
77
#### report
78
-
Type: `string`
79
-
Choices: `'min'`, `'gzip'`
78
+
Type: `string`
79
+
Choices: `'min'`, `'gzip'`
80
80
Default: `'min'`
81
81
82
82
Report minification result or both minification and gzip results.
83
83
This is useful to see exactly how well uglify-js is performing but using `'gzip'` will make the task take 5-10x longer to complete. [Example output](https://github.com/sindresorhus/maxmin#readme).
84
84
85
85
#### sourceMap
86
-
Type: `Boolean`
86
+
Type: `Boolean`
87
87
Default: `false`
88
88
89
89
If `true`, a source map file will be generated in the same directory as the `dest` file. By default it will have the same basename as the `dest` file, but with a `.map` extension.
90
90
91
91
#### sourceMapName
92
-
Type: `String``Function`
92
+
Type: `String``Function`
93
93
Default: `undefined`
94
94
95
95
To customize the name or location of the generated source map, pass a string to indicate where to write the source map to. If a function is provided, the uglify destination is passed as the argument and the return value will be used as the file name.
96
96
97
97
#### sourceMapIn
98
-
Type: `String``Function`
98
+
Type: `String``Function`
99
99
Default: `undefined`
100
100
101
101
The location of an input source map from an earlier compilation, e.g. from CoffeeScript. If a function is provided, the
102
102
uglify source is passed as the argument and the return value will be used as the sourceMap name. This only makes sense
103
103
when there's one source file.
104
104
105
105
#### sourceMap.includeSources
106
-
Type: `Boolean`
106
+
Type: `Boolean`
107
107
Default: `false`
108
108
109
109
Pass this flag if you want to include the content of source files in the source map as sourcesContent property.
110
110
111
111
###### sourceMap.root
112
-
Type: `String`
112
+
Type: `String`
113
113
Default: `undefined`
114
114
115
115
With this option you can customize root URL that browser will use when looking for sources.
116
116
117
117
If the sources are not absolute URLs after prepending of the `sourceMap.root`, the sources are resolved relative to the source map.
118
118
119
119
#### sourceMap.url
120
-
Type: `String`
120
+
Type: `String`
121
121
Default: `undefined`
122
122
123
123
Override the calculated value for `sourceMappingURL` in the source map. This is useful if the source map location is not relative to the base path of the minified file, i.e. when using a CDN
124
124
125
125
#### wrap
126
-
Type: `String`
126
+
Type: `String`
127
127
Default: `undefined`
128
128
129
129
Wrap all of the code in a closure, an easy way to make sure nothing is leaking.
130
130
For variables that need to be public `exports` and `global` variables are made available.
131
131
The value of wrap is the global variable exports will be available as.
132
132
133
133
#### output.ascii_only
134
-
Type: `Boolean`
134
+
Type: `Boolean`
135
135
Default: `false`
136
136
137
137
Enables to encode non-ASCII characters as \uXXXX.
138
138
139
139
#### output.comments
140
-
Type: `Boolean``String``Function`
141
-
Default: `undefined`
140
+
Type: `Boolean``String``Function`
141
+
Default: `undefined`
142
142
Options: `false``'all'``'some'`
143
143
144
144
Turn on preservation of comments.
@@ -150,51 +150,51 @@ Turn on preservation of comments.
150
150
-`RegExp``'/[RegExp]/'` will preserve comments matching given RegExp or stringified RegExp
151
151
152
152
#### banner
153
-
Type: `String`
153
+
Type: `String`
154
154
Default: `''`
155
155
156
156
This string will be prepended to the minified output. Template strings (e.g. `<%= config.value %>` will be expanded automatically.
157
157
158
158
#### footer
159
-
Type: `String`
159
+
Type: `String`
160
160
Default: `''`
161
161
162
162
This string will be appended to the minified output. Template strings (e.g. `<%= config.value %>` will be expanded automatically.
163
163
164
164
#### ie8
165
-
Type: `Boolean`
165
+
Type: `Boolean`
166
166
Default: `false`
167
167
168
168
Set this to `true` if you still care about full compliance with Internet Explorer 6-8 quirks.
169
169
170
170
#### mangle.properties
171
-
Type: `Boolean``Object`
171
+
Type: `Boolean``Object`
172
172
Default: `false`
173
173
174
174
Turn on or off property mangling with default options. If an `Object` is specified, it is passed directly to `ast.mangle_properties()` (mimicking command line behavior). [View all options here](https://github.com/mishoo/UglifyJS2#mangler-options).
175
175
176
176
#### reserveDOMProperties
177
-
Type: `Boolean`
177
+
Type: `Boolean`
178
178
Default: `false`
179
179
180
180
Use this flag in conjunction with `mangle.properties` to prevent built-in browser object properties from being mangled.
181
181
182
182
#### exceptionsFiles
183
-
Type: `Array`
183
+
Type: `Array`
184
184
Default: `[]`
185
185
186
186
Use this with `mangle.properties` to pass one or more JSON files containing a list of variables and object properties
187
187
that should not be mangled. See the [UglifyJS docs](https://www.npmjs.com/package/uglify-js) for more info on the file syntax.
188
188
189
189
#### nameCache
190
-
Type: `String`
190
+
Type: `String`
191
191
Default: `''`
192
192
193
193
A string that is a path to a JSON cache file that uglify will create and use to coordinate symbol mangling between
194
194
multiple runs of uglify. Note: this generated file uses the same JSON format as the `exceptionsFiles` files.
195
195
196
196
#### output.quote_style
197
-
Type: `Integer`
197
+
Type: `Integer`
198
198
Default: `0`
199
199
200
200
Preserve or enforce quotation mark style.
@@ -525,7 +525,7 @@ grunt.initConfig({
525
525
526
526
## Release History
527
527
528
-
* 2017-11-26 v3.2.0 Update uglify-js to v3.2.0.
528
+
* 2017-11-26 v3.2.1 Update uglify-js to v3.2.0.
529
529
* 2017-09-11 v3.1.0 Update uglify-js to v3.1.0.
530
530
* 2017-05-20 v3.0.1 Fix toplevel option.
531
531
* 2017-05-12 v3.0.0 Update uglify-js to v3.0.4.
@@ -572,4 +572,4 @@ grunt.initConfig({
572
572
573
573
Task submitted by ["Cowboy" Ben Alman](http://benalman.com)
574
574
575
-
*This file was generated on Mon Sep 11 2017 13:21:40.*
575
+
*This file was generated on Sun Nov 26 2017 08:57:08.*
0 commit comments