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

[Base] Use a mutation observer to destroy instances of removed DOM elements #552

Closed
titouanmathis opened this issue Nov 28, 2024 · 0 comments · Fixed by #559
Closed

[Base] Use a mutation observer to destroy instances of removed DOM elements #552

titouanmathis opened this issue Nov 28, 2024 · 0 comments · Fixed by #559

Comments

@titouanmathis
Copy link
Contributor

Instances added to the global instances map are kept in memory even if their root element has been removed from the DOM. This might lead to unexpected behaviors when using the getInstances() function.

We should watch for DOM changes and correctly destroy instance when their root element is not in the DOM anymore.

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

Successfully merging a pull request may close this issue.

1 participant