Skip to content
This repository has been archived by the owner on Aug 2, 2024. It is now read-only.

Add support for nested retargeted shadow roots #10

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

AllenWilliamson
Copy link

This fixes an issue where callbacks are fired multiple times if the event is triggered from within nested shadow roots.

This may be something that only I am experiencing due to how much I am using web components but I figured I would share my workaround in case it helps others.

- Refactor `dispatchEvent` `if` statements
- Add `event._retargetEventElements`
- Modify `dispatchEvent` to return `true` or `false`
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant