Why is jQuery not integrated within the browser

前端 未结 7 1194
死守一世寂寞
死守一世寂寞 2020-12-06 16:20

Why isn\'t jQuery intergrated into browsers, so there would be no need to have to reference it on your site, and instead, the browser just notices the jQuery used, and every

7条回答
  •  我在风中等你
    2020-12-06 16:40

    Because then different browsers would have different incompatible versions.

    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.

    It would also break other libraries that define $ functions (eg, Prototype).

提交回复
热议问题