You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When the Image Transform plugin processes these images with multiple formats, it creates <picture> elements (🎉). But there's a small problem with that in this particular case:
The attributes on the <img> element stick with said element, which makes sense 99% of the time. But in this case, the web component breaks unless the slot attribute is on the <picture> itself (<picture slot="image-1">).
I couldn't see a way to specify which attributes should stick with <img> versus <picture>. I tried adding a <picture> element with a slot ahead of time, but it looks like that won't be a feasible fix until/unless #214 is addressed. In the meantime I'm going to put eleventy:ignore on these for now, but figured I'd create an issue. ❤️
The text was updated successfully, but these errors were encountered:
On my personal blog, I have a few posts that use my company's image comparison web component. Here's some simplified markup for that:
When the Image Transform plugin processes these images with multiple formats, it creates
<picture>
elements (🎉). But there's a small problem with that in this particular case:The attributes on the
<img>
element stick with said element, which makes sense 99% of the time. But in this case, the web component breaks unless theslot
attribute is on the<picture>
itself (<picture slot="image-1">
).I couldn't see a way to specify which attributes should stick with
<img>
versus<picture>
. I tried adding a<picture>
element with aslot
ahead of time, but it looks like that won't be a feasible fix until/unless #214 is addressed. In the meantime I'm going to puteleventy:ignore
on these for now, but figured I'd create an issue. ❤️The text was updated successfully, but these errors were encountered: