# Event Capturing and Bubbling in JavaScript

**URL:** <https://forum.kirupa.com/t/event-capturing-and-bubbling-in-javascript/352070>\
**Category:** programming\
**Created:** [November 21, 2014, 4:02am UTC](https://forum.kirupa.com/t/event-capturing-and-bubbling-in-javascript/352070 "2014-11-21T04:02:05Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![kirupa](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/kirupa/32/11616_2.png) [@kirupa](https://forum.kirupa.com/u/kirupa)\
**Post date:** [November 21, 2014, 4:02am UTC](https://forum.kirupa.com/t/event-capturing-and-bubbling-in-javascript/352070/1 "2014-11-21T04:02:07Z")

</div>

Get a deeper look at how events work by understanding bubbling, capturing, stopping propagation, and more!

* * *
This is a companion discussion topic for the original entry at [http://www.kirupa.com/html5/event\_capturing\_bubbling\_javascript.htm](http://www.kirupa.com/html5/event_capturing_bubbling_javascript.htm)

---

<div class="post-metadata">

**Author:** ![bantuist](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/bantuist/32/8348_2.png) [@bantuist](https://forum.kirupa.com/u/bantuist)\
**Post date:** [April 6, 2017, 2:15am UTC](https://forum.kirupa.com/t/event-capturing-and-bubbling-in-javascript/352070/2 "2017-04-06T02:15:37Z")

</div>

Hello, great article and clear explanation of event propagation!

One question: in the article you say that events start at the root of the document and the diagrams shows the window object as the starting point.

Isn’t the html element the root element of the document?

Where exactly does capturing start and bubbling end?

---

<div class="post-metadata">

**Author:** ![ninedeadeyes](https://avatars.discourse-cdn.com/v4/letter/n/b38774/32.png) [@ninedeadeyes](https://forum.kirupa.com/u/ninedeadeyes)\
**Post date:** [March 24, 2022, 11:56am UTC](https://forum.kirupa.com/t/event-capturing-and-bubbling-in-javascript/352070/3 "2022-03-24T11:56:42Z")

</div>

Is there really any need for the Propagation to be called within the clickHandler function ? It has already been interrupted already.

---

<div class="post-metadata">

**Author:** ![ninedeadeyes](https://avatars.discourse-cdn.com/v4/letter/n/b38774/32.png) [@ninedeadeyes](https://forum.kirupa.com/u/ninedeadeyes)\
**Post date:** [March 24, 2022, 12:03pm UTC](https://forum.kirupa.com/t/event-capturing-and-bubbling-in-javascript/352070/4 "2022-03-24T12:03:33Z")

</div>

Technically the ‘root’ is at the top of the tree so it starts and end there but I have seen other stuff online that is little misleading stating it is the HTML but to be honest I don’t think it really matters in the grand scheme of things. I think the confusion comes because technically the window isn’t part of the DOM but one shouldn’t lose sleep over this.
