@ludovic
If I understood you right you are supporting conditional compilation
idea, but done in jQuery?
Can you elaborate please?
Am I right in thinking that this can lead to a very clever system,
that will increase every page HTTP GET time ?
It is relatively easy to imagine and implement a little jQuery loader
that will load up additional needed parts, in accordance with which is
the browser host. Dynamic composition? Very modern term ;o)
PSEUDO CODE :
// at this point only minimal jQ is loaded
$( function () {
// load jQ part 1
if ( is_supported_X() ) $.getScript ( .... ) else $.getScript
( .... ) ;
// load jQ part 2
if ( is_supported_Y() ) $.getScript ( .... ) else $.getScript
( .... ) ;
// load jQ part 3
if ( is_supported_Z() ) $.getScript ( .... ) else $.getScript
( .... ) ;
// load jQ part 4
if ( is_supported_W() ) $.getScript ( .... ) else $.getScript
( .... ) ;
// and so on untill we have assembled all we need
})
This could be at the bottom of the single minimal js file needed ...
AFAIK, Dojo, ExtJs etc ... all have a conceptually simillar mechanism
for dynamic and transparent addition of necessary parts.
--DBJ
On Aug 20, 2:32 pm, ludovic <[email protected]> wrote:
> Another point to add :
> Even if two different browsers respond to the same features detection,
> one browser can only correspond to one combinaison of features
> detection. I understand that in developpment, it is cleaner to use
> features detection, but there should be a compilation for most used
> browsers.
>
> We don't even need to make it for every browser. Just for IE 6, IE7,
> IE 8, FF2, FF3.0, FF3.5, Safari 3.1 and some others.
> If the browser doesn't correspond to one of precomputed files, it will
> simply download the full file as we do actually.
>
> In a certain way, it is the creation of a precompiler like //@cc_on
> but enhanced.
>
> Regards
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"jQuery Development" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/jquery-dev?hl=en
-~----------~----~----~----~------~----~------~--~---