- Events execution order is not guaranteed based on the heirarchy of the DOM when using
window.addEventListener
. Insteadwindow.addEventListener
will run listeners in the order they are registered. - DOM3 specifies events flow down the DOM tree and then back up.
addEventListener
's are called on the way back up, but can be called as evt propogates down the tree withtrue
for theuseCapture
argument.
Taking control of event listeners for the user limits a lot of the flexibility the DOM + JS provides. See this issue for an example.
Basically, we have not covered bubbling and cancellation DOM Events with LiveView.