views:

212

answers:

2

I've been always thinking that DOMNodeInsertedIntoDocument/DOMNodeRemovedFromDocument events should not bubble, and for me that made enough sence. However, just recently I looked into specification once again and found out that in one location it says these events should not bubble (Complete list of event types), while in other location is says they should (DOMNodeInsertedIntoDocument and DOMNodeRemovedFromDocument).

I've also looked up on the Internet and found several implementations, all of them are different in the behavior implemented.

The question is: Should these events actually bubble ot not? What do you think make more sence?

Update: Found out that in DOM-Level-2-Events specification there is no ambiguity since it olny mentions these events in a single location.

Update 2: This question was asked in order to validate the behavior of these events in the Ample SDK Ajax Framework that aims to implement all standards-based technologies.

+1  A: 

I guess you already discovered that they should not bubble. But it is a moot point for a practical developer because they are not supported by IE, which still holds ~80% of the market. :-(

Eugene Lazutkin
A: 

I would go with ‘No’, as per Level 2 Events, which is a proper Recommendation that has been around a long time and has errata that do not include anything to do with this. DOM Level 3 Events is only a Working Group Note and still WD, which is a bit unsatisfactory all round.

bobince