W3C home > Mailing lists > Public > public-webapps@w3.org > July to September 2010

[DOMCore] Attr

From: Anne van Kesteren <annevk@opera.com>
Date: Fri, 10 Sep 2010 14:35:22 +0200
Cc: "WebApps WG" <public-webapps@w3.org>
To: "Ojan Vafai" <ojan@chromium.org>, "Maciej Stachowiak" <mjs@apple.com>, "Jonas Sicking" <jonas@sicking.cc>, "Boris Zbarsky" <bzbarsky@mit.edu>, "Olli@pettay.fi" <Olli@pettay.fi>, "Adrian Bateman" <adrianba@microsoft.com>
Message-ID: <op.vitg87a764w2qv@anne-van-kesterens-macbook-pro.local>
Hi,

I thought I'd email some people directly to figure out what we can do with  
Attr as it is one of the last bits not defined yet in Web DOM Core and I  
would sort of like to handle it so the specification is "complete" (at  
least beyond the initial 80%).

Attr nodes have traditionally allowed child nodes to account for  
EntityReference nodes, a concept which no browser vendor implemented.  
While it is great nobody implemented the complexity that is  
EntityReference, it has left us with a fair bit complexity for Attr nodes,  
which is implemented.

There are several ways we can simplify Attr nodes (some are orthogonal):

1) We can drop the concept of Attr nodes having children. In Gecko it  
already depends on how you created the Attr node [1][2] whether it can  
have children or not. I think we should either consistently allow children  
or not at all (preferred).

2) We can drop the concept of Attr being a Node. This would drastically  
reduce the footprint of the object. The difficulty would be in figuring  
out what we would need to preserve. Ideally someone implements this in a  
nightly and figures it out.

3) We can drop the concept of Attr being an object altogether. I do not  
think this is doable compatibility-wise, but not having Node.attributes,  
Attr, and just using  
getAttribute/getAttributeNS/setAttribute/setAttributeNS would be very nice  
complexity-wise.

If there is anything else I have not considered that can we try out please  
mention it! Any input on this is much appreciated.

Kind regards,


[1]<http://software.hixie.ch/utilities/js/live-dom-viewer/saved/625>
[2]<http://software.hixie.ch/utilities/js/live-dom-viewer/saved/626>


-- 
Anne van Kesteren
http://annevankesteren.nl/
Received on Friday, 10 September 2010 12:36:10 GMT

This archive was generated by hypermail 2.3.1 : Tuesday, 26 March 2013 18:49:40 GMT