We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 351ef5f commit 2d53b22Copy full SHA for 2d53b22
README.md
@@ -568,3 +568,17 @@ Example:
568
`<a href="https://example.com" id="myLink" onclick="PreventDefault(event)">Go to Example</a>`
569
570
Normally, clicking the link would take you to example.com. PreventDefault method stops that action and does something else—like showing an alert.
571
+
572
+`StopPropagation` prevents the event from occurring on its parent tags.
573
574
+Example:
575
576
+`StopPropagation(event)`
577
578
+```html
579
+<div onclick="alert('DIV clicked!')">
580
+ <button onclick="StopPropagation(event)">Click Me</button>
581
+</div>
582
+```
583
584
+In the above example, the alert is not displayed when the button is clicked.
0 commit comments