[jquery-dev] Re: Separation of browser-specific code

2009-08-20 Thread DBJDBJ
It is a good idea. Not so much for "sniffing" out each and every browser, but for having one version for all non IE browsers and several jQ versions for several IE versions ;o) The “ultimate solution" would be this:

[jquery-dev] Re: Separation of browser-specific code

2009-08-20 Thread lrbabe
jQuery is doing something similar with its "support" object: http://docs.jquery.com/Utilities/jQuery.support It uses feature detection once at the script initialization and then uses boolean values to determine which code is appropriate.. On Aug 20, 7:50 am, ludovic wrote: > > It is a bad idea b

[jquery-dev] Re: Separation of browser-specific code

2009-08-19 Thread ludovic
> It is a bad idea because there is no such thing as foolproof browser > sniffing. > The only way to know what the browser can do is to test its features, > and loading a piece of script for every feature implementation > specific to a browser completely kills the benefit of loading less > script.

[jquery-dev] Re: Separation of browser-specific code

2009-08-19 Thread John Resig
That would assume that it's possible to split jQurey components out by browser - but it is not. All bug fixes are handled on-the-fly, determined using feature detection. Although, the vast majority of the detections do target IE. --John On Wed, Aug 19, 2009 at 5:18 PM, ludovic wrote: > > A tec

[jquery-dev] Re: Separation of browser-specific code

2009-08-19 Thread lrbabe
It is a bad idea because there is no such thing as foolproof browser sniffing. The only way to know what the browser can do is to test its features, and loading a piece of script for every feature implementation specific to a browser completely kills the benefit of loading less script. Beside, jQ