Skip to content

Commit 3374c5d

Browse files
committed
Merge pull request #502 from getsentry/mangle-props
Configure Uglify to mangle prop names beginning with _
2 parents 86d1685 + cb0a848 commit 3374c5d

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed

Gruntfile.js

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -176,8 +176,22 @@ module.exports = function(grunt) {
176176

177177
// Only preserve comments that start with (!)
178178
preserveComments: /^!/,
179+
180+
// Minify object properties that begin with _ ("private"
181+
// methods and values)
182+
mangleProperties: {
183+
regex: /^_/
184+
},
185+
179186
compress: {
187+
booleans: true,
188+
conditionals: true,
180189
dead_code: true,
190+
join_vars: true,
191+
pure_getters: true,
192+
sequences: true,
193+
unused: true,
194+
181195
global_defs: {
182196
'TEST': false
183197
}

0 commit comments

Comments
 (0)