- From: Jonas Sicking <jonas@sicking.cc>
- Date: Mon, 20 Jun 2011 00:06:14 -0700
- To: Boris Zbarsky <bzbarsky@mit.edu>
- Cc: www-dom@w3.org
On Sun, Jun 19, 2011 at 10:49 PM, Boris Zbarsky <bzbarsky@mit.edu> wrote: >> I assume that web compatibility requires attributes to be live. > > It may well, yes.... In which case the current spec text is probably not > ok. Data would be good. I think live is preferable for other reasons too. First off it's a good idea for consistency with similar properties. Second, code like the following would be very inefficient otherwise: for (i = 0; i < el.attributes.length; i++) { if (el.attributes[i].name == "foo" || el.attributes[i].name == "bar") doStuff(el.attributes[i].value); else doOtherStuff(el.attributes[i].value); } / Jonas
Received on Monday, 20 June 2011 07:07:15 UTC