srcset
noun
say it: “SORSS set” /ˈsɔrs sɛt/
An image attribute that lists several versions of the same picture, each with its width or screen sharpness, so the browser can pick one.
What is srcset?
srcset — An attribute listing image candidates with width or pixel-density descriptors.
<img src="photo-800.jpg"
srcset="photo-400.jpg 400w, photo-800.jpg 800w"
alt="Community garden">
In a sentence
- “The srcset lists lighthouse-480.jpg, lighthouse-960.jpg and lighthouse-1600.jpg with their widths.”
Level: Journeyman · More HTML terms at this level
Updated