stopImmediatePropagation
stopImmediatePropagation is a method on Event objects in web browsers. When invoked from an event listener, it immediately stops the event from continuing to propagate and also prevents any remaining listeners on the same target for that event from being called. In practice, after the call the event will not bubble up to ancestor elements, and other listeners registered on the current element for the same event type will not run.
This behavior differs from stopPropagation, which halts propagation to ancestor elements but may still allow other
Important to note is that stopImmediatePropagation does not by itself prevent the browser’s default action for
Usage considerations include the potential to disrupt other scripts or libraries that rely on event listeners
Compatibility is broad across modern browsers; it is supported in Chrome, Firefox, Safari, Edge, and IE9 and