Frage

I'm not sure if there is a tool to do this but thought I'd ask.

We are building a Javascript library based on jQuery. As it grows the filesize is becoming quite big. We release both a minified and non-minified version. Or clients want the non-minified version for development as it helps them debug. However, as said, the filesize is quite large now.

Are there any tools that can do some cleaning or compressing without minifying to at least reduce the filesize a little? Maybe simple things like reducing some needless whitespace or formatting the code a little?

Of course in production they will use the minified library but even in DEV they have complained of the large file-size, though we cannot get around that while still adding functionality.

Thank you!

War es hilfreich?

Lösung

You can use Google's closure compiler http://closure-compiler.appspot.com/ It supports not only minifying but also allows to remove the whitespaces & prettyprint

Lizenziert unter: CC-BY-SA mit Zuschreibung
Nicht verbunden mit StackOverflow
scroll top