Re: ISSUE-41/ACTION-97 decentralized-extensibility

Anne van Kesteren On 09-10-19 13.02:

> On Sun, 18 Oct 2009 21:42:54 +0200, Adrian Bateman  
> <> wrote:
>> I meant something like <widget:datepicker>, <widget:menubar>,  
>> <widget:treecontrol>. This seems fairly common in JavaScript control  
>> libraries and finding all instances of controls provided by the library  
>> is necessary. Page start-up performance for this kind of behaviour is  
>> important. Something like this is where you might also want to style  
>> across elements with CSS as Tony suggested. Of course, this is only one  
>> of the suggested use cases but I think it's a reasonably compelling one.
> FWIW, I believe in quite a few engines class names would be even more  
> performant. With getElementsByClassName() (not yet in IE I believe) you'd  
> also have a convenient way to get them. They would also work better if you  
> have e.g. child nodes that you do not want to see returned in the  
> collection.
> For a set of element names you could also use querySelector().

I don't know what will be most "performant", but I don't think the 
primary argument for namespaces from either Adrian or Tony has 
been performance speed. That is not the only concern for authors, 
anyway. Of course, if an important UA doesn't react to namespaces 
or namespaces aren't "performant" enough, then one must add 
classes etc. Authors do a lot to make up for unperforming user 
agents. But maintaining an up-to-date document with all class 
names in place in all the necessary places, is more demanding for 
authors, than using powerful selectors that are able to select the 
already present data structure.

Perhaps, as one of the editors of Namespaces in CSS[1], you are 
also able to tell us that namespaces have some advantages?

leif halvard silli

Received on Monday, 19 October 2009 11:51:10 UTC