Firefox does not support hasAttributes (not even on Element). It is not part of the latest DOM spec either. It sounds like a high risk. We should watch the outcome of this battle: https://bugzilla.mozilla.org/show_bug.cgi?id=849661
Looks like Mozilla folks are removing it in part due to believing that WebKit doesn't support it? "WebKit seems not to support the method, so probably there's no big compat risk."
Yeah, whoops -- I tested a non-element for support. At this point I think it should be re-added to the spec. Spec bug: https://bugs.webkit.org/show_bug.cgi?id=113580
I meant: https://www.w3.org/Bugs/Public/show_bug.cgi?id=21522
> Looks like Mozilla folks are removing it in part due to believing that WebKit doesn't support it? Webkit had it, but removed it. I discovered this from some code that broke in Chrome 25. http://code.google.com/p/chromium/issues/detail?id=222421 Webkit had it, then removed it. Firefox decided to remove it because Webkit doesn't have it. The core question here is why was it removed from Webkit in the first place.
WebKit didn't remove it, it moved it from Node to Element. This follows the newer DOM spec. I don't get why the spec moves things like this, though.
(In reply to comment #5) > WebKit didn't remove it, it moved it from Node to Element. This follows the newer DOM spec. I don't get why the spec moves things like this, though. Only elements can have attributes so having attribute related APIs on non Elements is nonsensical.
All browsers support it now as per MDN, I don't think we are going to remove it: Link - https://developer.mozilla.org/en-US/docs/Web/API/Element/hasAttributes I am going to mark this as "RESOLVED WONTFIX". Please ignore, if I am wrong and mark it accordingly. Thanks!