[wp-hackers] Packing JavaScript
Charles
lists07 at wiltgen.net
Tue Sep 18 18:36:31 GMT 2007
> The *only* point of packing javascript is to reduce filesize and
> thus reduce bandwidth usage.
Another plus is speed benefits for end users.
> It is not possible to create a packing system that works on all
> javascript code all the time.
For simple packing systems, that's absolutely true.
"Real" JavaScript compressors like YUI Compressor (which use a "real"
JavaScript parser) are perfectly reliable with good code, in my experience.
> Bandwidth reduction is often better achieved by compression, and
> this is arguably a server side thing to do.
JavaScript compression complements generic text compression nicely. I use
"SetOutputFilter DEFLATE", and that works very well.
Anyway, the combination of (1) JavaScript compression, (2) generic
server-side text compression and (3) file-combining is the norm, not the
exception, for sites that uses JavaScript for anything more serious than
roll-overs.
-- Charles
More information about the wp-hackers
mailing list