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

Handling connectedCallback and disconnectedCallback #1

Closed
EisenbergEffect opened this issue Mar 14, 2020 · 3 comments
Closed

Handling connectedCallback and disconnectedCallback #1

EisenbergEffect opened this issue Mar 14, 2020 · 3 comments

Comments

@EisenbergEffect
Copy link

I had a read through the code. It's all pretty straight forward and makes good sense. However, the way that the connected/disconnected functionality is mixed in seems a bit odd, and also not accounting for a common scenario where many if not all web components will define those callbacks.

If the callback is present, could we instead wrap the original? Also, can we get away from leveraging __proto in the mixin implementations?

Other than those two issues, this looks pretty solid. Thanks for working on it!

@sheeshpaul
Copy link
Owner

Thanks for your feedback. As you suggested, I have wrapped connectedCallback and disconnectedCallback and there is no need to call connect/disconnect state functions, and also removed the proto. These changes have been published in version 2.0.0

@sheeshpaul
Copy link
Owner

Fixed in version 2.0.0

@EisenbergEffect
Copy link
Author

Nice!

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

2 participants