[jQuery] jQuery 1.1 by the end of Nov
Fairly new to Jquery, but from what I see already, the amount of code that
needs to be written is very minimal when using jquery. I am currently
converting about 5 js files totaling about 1000+ lines of js code to utilize
jquery and already took one js file the was 549 lines (uncompressed) and 12k
to about 223 lines and about 4k. Point is, if the jquery file is 20k or
even a little more, the amount of code that would be saved is a good trade
off in my mind.
Now granted, that is my sites situation. Some sites may be using jquery
only for the toggle. So maybe there should be a lite version for those
people.
Just my two cents.
-----Original Message-----
From: discuss-bounces@jquery.com [mailto:discuss-bounces@jquery.com] On
Behalf Of Corey Jewett
Sent: Tuesday, November 14, 2006 8:33 PM
To: jQuery Discussion.
Subject: Re: [jQuery] jQuery 1.1 by the end of Nov
The problem with all this is that 4 js files totaling 20K is will
typically make your page load slower than 1 20K JS file. There are a
couple reasons:
1) round trip time per each additional requests for each file.
Roughly equivalent to ping lag + server processing time. I wouldn't
be surprised if this was an extra 250 millis per request.
2) the HTTP RFC suggests a maximum of 4 open connections from a
client to a server. More files == larger backlog of files == poorer
utilization of broadband connections.
3) HTTP pipelining (assuming it's even turned on, which it frequently
isn't since it wastes server resources) can theoretically mitigate
#2, but will not do much for #1. It'll cut out repeated setup and
teardown of TCP stacks.
4) I haven't done any recent research on it, but don't browsers tend
to cache JS files anyway?
Now having said all that, if you still want to whittle down the file
size, can I make a vote to maybe yank serialization, but nothing
else. From the response so far it appears that there's a pretty even
split between people who use/don't FX and/or AJAX. Meaning that
pulling either one out is sure to screw up the other half.
I could get on board with releasing several packages, as somebody
suggested:
JQuery: src/jquery + src/events + src/fx + src/ajax
JQuery-fx-only: src/jquery + src/events + src/fx
JQuery-ajax-only: src/jquery + src/events + src/ajax
Jquery-dom-only: src/jquery + src/events
JQuery-lite: src/jquery
This just seems likely to generate a lot of extra support problems on
the mailing list. Can't we just leave it up to people to build their
own if they really want to cut it down below 20K?
Corey