From 8016413d479a6ada03446140862061e778d986b7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=BCrg=20Lehni?= Date: Sat, 1 Jun 2013 16:45:35 -0700 Subject: [PATCH] Fix issues with uglifyjs. Workarounds so far, needs proper fixing in uglifyjs. --- build/minify.sh | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/build/minify.sh b/build/minify.sh index 1a1f29a3..6b564e03 100755 --- a/build/minify.sh +++ b/build/minify.sh @@ -12,4 +12,7 @@ # We need to keep dead_code around for now, since the very odd JavaScriptCore # scope bug fix (nop().nop()) requires it. -uglifyjs ../dist/paper.js -o ../dist/paper-min.js -c unused=false,dead_code=false -m -r "_$_,$_" -b ascii_only=true,beautify=false --comments /^!/ +# TODO: uglifyjs gets confused about Base and Color constructor naming, so we +# have to tell it to not rename these. It's also not renaming all the local +# references to classes which could yield a lot of size improvements. +uglifyjs ../dist/paper.js -o ../dist/paper-min.js -c unsafe=true,unused=false,dead_code=false,hoist_funs=false -m -r "Base,Color,_$_,$_" -b ascii_only=true,beautify=false --comments /^!/