News for hackers. Stuff that matters.
Re:jRails - jQuery on Rails by michelson01 on Wednesday November 21, 2007 @05:08PM (#82583)
i thought one of the big advantages of jQuery was the smaller size of the javascript file(s).

but this demo uses 106k of javascript (and it's not compressed for some reason)

photo from web developer extension: http://myskitch.com/michelson/document_size_-_http__ennerchi...

Re:jRails - jQuery on Rails by veritas on Wednesday November 21, 2007 @05:41PM (#82596)
The base jQuery is very light, perhaps half the size of Prototype if I recall correctly.

The added bloat comes from the effects and UI libraries. The UI library is probably superfluous so that should cut the size significantly.

Re:jRails - jQuery on Rails by zach on Wednesday November 21, 2007 @08:27PM (#82628)
I haven't seen where Rails natively supports using different Javascript files in production than in development -- I've always done it myself. Then again, jQuery hasn't been attached to Rails before, so that's understandable too.

Without that being set up, either you run on the minified version of jQuery (a developer-hostile move), or the big old version with all the comments, which is inconvenient for the user. For a 0.1 release, they made the right call putting in the full versions of the Javascript so you have a chance of seeing what's happening if something goes wrong.