[whatwg] getElementsByClassName

On Tue, 6 Sep 2005, Lachlan Hunt wrote:
>
> [DOMTokenString]
> 
> I've thought about it some more, and it may be difficult to do with the 
> way the add() and remove() are currently defined with no return value. I 
> assume that means you're intending for these functions to modify the 
> string itself. However, in JavaScript a String() is immutable and all 
> other methods that do modifications actually return a new string, not 
> modify itself.

I've changed the approach to address this. (Thanks to you and Maciej and 
others.)


> Then, there's also the question of assuming the token delimiter will 
> always be a space.  Will there need to be a way to specify what the 
> delimiter is, or is that intended to be dependant upon the language? For 
> example, in HTML .className would return a DOMTokenString delimited by 
> spaces, but in FooBarML it may be semi-colons, commas, or anything else.

I think unless we have an actual use case we can leave the implied 
space separator as is. It can always be extended later.

-- 
Ian Hickson               U+1047E                )\._.,--....,'``.    fL
http://ln.hixie.ch/       U+263A                /,   _.. \   _\  ;`._ ,.
Things that are impossible just take longer.   `._.-(,_..'--(,_..'`-.;.'

Received on Monday, 6 August 2007 19:25:17 UTC