开发者

Why isn't jQuery native to browsers, i.e. pre-downloaded? [duplicate]

This question already has answers here: Why web browsers don't have jQuery built in? [duplicate] (8 answers) 开发者_StackOverflow Why is jQuery not integrated within the browser (7 answers) Closed 5 years ago.

jQuery very popular, so why don't browsers wire in the last few versions of jQuery, going a little further than the current CDN?

No more downloading, no more manual updating, pre-compilation of the library (faster loading time), less worry for developers, better browsing experience for users, etc.


I would assume version control is the fear...

different sites use different versions of jQuery...

AND

the last thing I want is the elephants in the room (google, microsoft, and mozilla) fighting over implementation details of a very successful and independant open source project...


That will defeat the point of jQuery.

Any native implementation is guaranteed to have some subtle difference from the real thing; eventually, we would need a cross-browser jQuery wrapper, and the cycle would repeat.

It would also make updates much more complicated.

re: EDIT:
That's already done.
Google serves jQuery from their public CDN with very heavy caching headers.

In practice, if you include jQuery from Google's CDN, it will usually be in the browser's cache.


Because jQuery is a framework; not a language.

So by supporting Javascript it supports jQuery.

I see your point, and perhaps it will become ubiquitous enough that it just comes wired in, but I doubt it.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜