-
Notifications
You must be signed in to change notification settings - Fork 43
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
HTML Web Component #405
Comments
Thanks. I saw both of those posts and think this would be a good idea. We already have both webc and Lit, so I'm not sure what the best approach would be. I think a "plain" HTML web component might be the way |
Yes, a plain one makes sense to me, too. Don't believe Lit is needed, since it's really about rendering a single element and it looks like you have all the prop logic extracted already. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
The web component version of unpic currently requires markup like this
I'd like to discuss an alternative markup:
The first advantage here is that it'll work without javascript. The idea is to enhance the
<img>
element instead of trying to replace it. The unpic-img element would take care of any non-standard attributes and modify the child image accordingly.This would break->change the current API. Could consider making another web component instead of breaking the current one made with LitElement.
See https://www.zachleat.com/web/a-taxonomy-of-web-component-types/#html-web-components and https://adactio.com/journal/20618 for more thoughts on this.
What do you think?
The text was updated successfully, but these errors were encountered: