aliel / groundskeeper-brunch

Brunch plugin to Clean javascript files, remove console.log ect... using groundskeeper
5 stars 2 forks source link

README update #1

Closed KATT closed 9 years ago

KATT commented 9 years ago

groundskeeper doesn't play that nicely with minified code. doing this makes sure that groundskeeper-brunch is run before in brunch's optimization step.

I got a problem where I had some code which, when obfuscated was [..],console.log('something'),[..] and groundskeeper removed the console.log but kept both the commas, resulting in a syntax error when run.

KATT commented 9 years ago

FYI, I ended up using UglifyJS' drop_console flag & using it as a preprocessor rather than groundskeeper pragmas. Didn't know that UglifyJS could do all of that.

Uglify is more well-maintained, stable and widely used library. I would try to direct users ending up here to check that out instead.