P.S. before somebody says that as feature detection it is not future prof ... well, IE9 in order to compete needs a totally redesigned JavaScript engine so my crystal ball says that most of IE oddity will disappear with version 9
Now put in this way, if I am right about this, i'll feel Nostradamus (lol) while if I am wrong, it won't be just me in troubles for old IE problems into version 9, but the entire Web ... so let's pray with me, or follow kangax post :-) On Mon, Sep 14, 2009 at 11:11 PM, Andrea Giammarchi < [email protected]> wrote: > Kean I do not get with who you are talking, is it me? I perfectly know > kangx post, I knew before (old codes in devpro) , and I use a strategy not > even mentioned in kangax post where the last fallback is always the IE one > to avoid redundancy and any kind of problem ... e.g. > > var slice = (function($slice){ > try { > $slice.call(document.childNodes); > function slice(list){ > return $slice.call(list); > }; > } catch(e) { > function slice(){ > for(var r = [], i = 0, length = list.length; i < length; ++i) > r[i] = list[i] > ; > return r; > }; > }; > return slice; > })(Array.prototype.slice); > > > I said about functions just because it is not only about var, being this is > the oddity post ... got it? :-) > > Regards > > On Mon, Sep 14, 2009 at 11:01 PM, Kean <[email protected]> wrote: > >> >> Well, if you didn't get it ... >> > --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
