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

getAttribute() in constructor #44

Closed
luwes opened this issue Dec 19, 2019 · 1 comment
Closed

getAttribute() in constructor #44

luwes opened this issue Dec 19, 2019 · 1 comment

Comments

@luwes
Copy link
Contributor

luwes commented Dec 19, 2019

Just a heads up, I fixed a small bug in lite-vimeo.

this.getAttribute() should not be called in the custom element constructor as it's possible the attribute is not defined yet at that point. happens when the script tag comes before the <lite-youtube> element.

luwes/lite-vimeo-embed@10f31db

https://stackoverflow.com/a/42251436/268820

@Garbee
Copy link
Contributor

Garbee commented Dec 20, 2019

Yup, working on this in #28. Thanks for the details as to why this practice should be discouraged though, useful to have written somewhere.

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