From 76408bc1ed52e149208acff221ef3956d61e4acc Mon Sep 17 00:00:00 2001 From: Deokjin Kim Date: Sat, 7 Jan 2023 16:56:34 +0900 Subject: [PATCH] doc: fix `event.cancelBubble` documentation Setter of `event.cancelBubble` is a no-op if the value passed to it is not `true`. Refs: https://dom.spec.whatwg.org/#interface-event PR-URL: https://github.com/nodejs/node/pull/45986 Reviewed-By: Antoine du Hamel Reviewed-By: Anna Henningsen --- doc/api/events.md | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/doc/api/events.md b/doc/api/events.md index 470451001753a8..70428b41c11d36 100644 --- a/doc/api/events.md +++ b/doc/api/events.md @@ -1748,14 +1748,16 @@ added: v14.5.0 This is not used in Node.js and is provided purely for completeness. -#### `event.cancelBubble()` +#### `event.cancelBubble` -Alias for `event.stopPropagation()`. This is not used in Node.js and is -provided purely for completeness. +* Type: {boolean} + +Alias for `event.stopPropagation()` if set to `true`. This is not used +in Node.js and is provided purely for completeness. #### `event.cancelable`