We're looking for a user researcher to understand the needs of developers and designers. Is this you or someone you know? Check out the post: https://mzl.la/2IGzdXS

event.cancelBubble Redirect 1


This feature has been removed from the Web. Though some browsers may still support it, it is in the process of being dropped. Do not use it in old or new projects. Pages or Web apps using it may break at any time.

Indicates if event bubbling for this event has been canceled or not.


event.cancelBubble = bool;
var bool = event.cancelBubble;

bool is the boolean value of true or false.


cancelBubble is set to false by default. This allows the event to bubble up the DOM, if it is a bubbleable event. Setting this property to true stops the event from bubbling up the DOM. Not all events are allowed to bubble up the DOM.

Use event.stopPropagation() instead of this non-standard method.

Document Tags and Contributors

Last updated by: Sheppy,