I use mod_deflate in my apache httpd to compress the js files. Nearly every modern browser supports contenttype gzip and you get a reduction from about 60 to 80% of the source files. One of the benefits is that you can compress any content (html, css, js ...)... Formerly i also tried js source compression, but i was not lucky about the results.

brgds

sigi

On 6/25/06, Sam <[EMAIL PROTECTED]> wrote:
> It is Java-based, so should run on windows without a problem. It isn't a
> polished GUI at the moment, you'll need to do a bit of scripting to get it

> set up.  More details here:

> http://dojotoolkit.org/docs/compressor_system.html

Here's a batch file I used to compress all my _javascript_s... It put the
compressed *.js files in a subfolder compress, and references the rhino.jar
on my drive D.

MD compress
FOR %%f IN (*.js) DO java -jar d:\rhino\custom_rhino.jar -c %%f >
compress/%%f 2>&1
Pause

I see about a 30% to 40% reduction in file size, and amazingly, everything
ran the first time.  Compressed prototype.js, script aculo, windows and
more...

I imagine the success of this compression engine is due to the hooks into
the Mozilla _javascript_ engine to get the parsing correct...

I'm happy to have found this tool.

Sam



_______________________________________________
Rails-spinoffs mailing list
Rails-spinoffs@lists.rubyonrails.org
http://lists.rubyonrails.org/mailman/listinfo/rails-spinoffs
_______________________________________________
Rails-spinoffs mailing list
Rails-spinoffs@lists.rubyonrails.org
http://lists.rubyonrails.org/mailman/listinfo/rails-spinoffs

Reply via email to