Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Potentially broken; will not re-define my custom element #8

Open
segfall opened this issue Nov 20, 2024 · 1 comment
Open

Potentially broken; will not re-define my custom element #8

segfall opened this issue Nov 20, 2024 · 1 comment

Comments

@segfall
Copy link

segfall commented Nov 20, 2024

Hello,

I've imported the redefine-custom-elements module and tried to use it with my HMR setup.

Unfortunately, on hot reload, I get this error:

DOMException: Failed to execute 'define' on 'CustomElementRegistry': the name "component-name" has already been used with this registry

Does this script still work for others?

@segfall
Copy link
Author

segfall commented Nov 20, 2024

Oddly enough, when I slow the execution down and debug through each statement in "redefine-custom-elements", no errors are reported in the console. However, my web component is still not hot-reloaded.

@segfall segfall changed the title Potentially broken; will not re-define plugin Potentially broken; will not re-define my custom element Nov 20, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant