I want srcset
and sizes
to relate to the container rather than the viewport
#61
aarongustafson
started this conversation in
Wants
Replies: 1 comment 1 reply
-
It would be nice, but I don't think browsers would be able to decide which image to load before the rendering is done, which would be much later than current feature. |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Currently, images with
srcset
andsizes
attributes can only be used relative to the viewport. When you have a more dynamic design where images are different widths depending on the content, you’d likesrcset
to relate to the container they’re in, and not the viewport.https://webwewant.fyi/wants/5f1aa74a3bfb5b5fff803e91/
Beta Was this translation helpful? Give feedback.
All reactions