Understanding Event Propagation
Step 1 of 5
Event bubbling is when an event starts at the element you clicked and then "bubbles up" to all its parent elements, triggering their event listeners too!
When you click an element, the event is like a bubble that rises up through all the parent elements, one by one, until it reaches the top of the page.
Each parent element with an event listener gets notified as the bubble passes through!
Imagine you have a button inside a div: