From 5eb492e90e973c777033d2a20a50c649eada1370 Mon Sep 17 00:00:00 2001 From: Randy Syring Date: Thu, 7 Sep 2017 23:25:50 -0400 Subject: [PATCH] Clarify order of bubble/capture handlers on the target The way the edited paragraph was written, I initially thought the bubble handler on the target would be ran before the capture handler, which seemed odd. I believe this update clarifies the author's intention and describes better how the handler's actually work. --- 2-ui/2-events/02-bubbling-and-capturing/article.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/2-ui/2-events/02-bubbling-and-capturing/article.md b/2-ui/2-events/02-bubbling-and-capturing/article.md index 6e39eae2..05da72fc 100644 --- a/2-ui/2-events/02-bubbling-and-capturing/article.md +++ b/2-ui/2-events/02-bubbling-and-capturing/article.md @@ -145,7 +145,7 @@ There are two possible values for that optional last argument: Note that while formally there are 3 phases, the 2nd phase ("target phase": the event reached the element) is not handled separately: handlers on both capturing and bubbling phases trigger at that phase. -If one puts a handler on the target element -- it triggers last on the capturing state, and first on the bubbling stage. +If one puts capturing and bubbling handlers on the target element, the capture handler triggers last in the capturing phase and the bubble handler triggers first in the bubbling phase. Let's see it in action: