diff --git a/build/pre-compile.js b/build/pre-compile.js index f6fade55c..912a8818c 100644 --- a/build/pre-compile.js +++ b/build/pre-compile.js @@ -200,6 +200,9 @@ // http://code.google.com/closure/compiler/docs/api-tutorial3.html#export source = source.replace(RegExp('\\.(' + propWhitelist.join('|') + ')\\b', 'g'), "['$1']"); + // remove brackets from `_.escape(__t)` in `tokenizeEscape` + source = source.replace("_['escape'](__t)", '_.escape(__t)'); + // remove whitespace from string literals source = source.replace(/'(?:(?=(\\?))\1.)*?'/g, function(string) { // avoids removing the '\n' of the `escapes` object