1. Home
  2. Html
  3. Picture

Responsive image sources. Media attribute accepts standard media queries.

#html#tag#responsive#media
<picture>
    <source media="(min-width: 1024px)" srcset="desktop-image.jpg">
    <source media="(min-width: 768px)" srcset="tablet-image.jpg">
    <img src="default-image.jpg" alt="Default mobile image">
</picture>
copy
Full Html cheatsheet