Bug 20494 - Text should have the features of ChildNode
Text should have the features of ChildNode
Status: RESOLVED WORKSFORME
Product: WebAppsWG
Classification: Unclassified
Component: DOM
unspecified
PC All
: P2 normal
: ---
Assigned To: Anne
public-webapps-bugzilla
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2012-12-22 02:23 UTC by Elliott Sprehn
Modified: 2012-12-22 09:35 UTC (History)
2 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Elliott Sprehn 2012-12-22 02:23:56 UTC
http://dom.spec.whatwg.org/#childnode

[[
Element implements ChildNode;
]]

Text should also implement ChildNode;

There's no reason you shouldn't be able to do nextElementSibling from a Text node, or do .before(...) on a Text node.
Comment 1 Elliott Sprehn 2012-12-22 02:24:42 UTC
In truth, we should probably have this for every node type. For example nextElementSibling should work on Comment nodes too.
Comment 2 Anne 2012-12-22 09:35:26 UTC
That's why CharacterData implements this interface too.