This is an archived snapshot of W3C's public bugzilla bug tracker, decommissioned in April 2019. Please see the home page for more details.

Bug 13375 - Don't define things in terms of attributes
Summary: Don't define things in terms of attributes
Status: RESOLVED FIXED
Alias: None
Product: WebAppsWG
Classification: Unclassified
Component: DOM (show other bugs)
Version: unspecified
Hardware: PC All
: P2 normal
Target Milestone: ---
Assignee: Anne
QA Contact: public-webapps-bugzilla
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-07-26 23:19 UTC by Ian 'Hixie' Hickson
Modified: 2012-02-17 15:10 UTC (History)
3 users (show)

See Also:


Attachments

Description Ian 'Hixie' Hickson 2011-07-26 23:19:19 UTC
DOMTokenList:

  If index is equal to or greater than the context object's length, then [...]

How to compare to an attribute is undefined. The attribute isn't a value, it's an attribute. Thus, does this mean comparing it against the value of the attribute at a particular time, or the pointer location of the attribute, or is it a lexical comparison against the name of the attribute, or what? What happens if the attribute is fiddled with in JS?

That's why I defined a variable and referenced that in the HTML version.
Comment 1 Anne 2011-07-31 09:01:13 UTC
For fiddling we have this text from HTML:

"When a method or an attribute is said to call another method or attribute, the user agent must invoke its internal API for that attribute or method so that e.g. the author can't change the behavior by overriding attributes or methods with custom properties or functions in ECMAScript."

So I guess if we just talk about "length attribute value" it should be fine? If it is not the changes you suggested for the Event interface are not correct either (where we moved from internal concepts for each attribute to just having attributes).
Comment 2 Anne 2012-02-17 15:10:48 UTC
It talks about the length attribute value now. If that is not okay, a lot of text will have to be changed, and not just in the DOM...