Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Responsive use of <img>
Search
Sponsored
·
Ship Features Fearlessly
Turn features on and off without deploys. Used by thousands of Ruby developers.
→
Juga Paazmaya
February 10, 2015
Technology
210
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Responsive use of <img>
A presentation held at [****] for Siili Solutions responsive design and prototyping team
Juga Paazmaya
February 10, 2015
More Decks by Juga Paazmaya
See All by Juga Paazmaya
Accessibility - Presented at TEKOS Workshop in 1st Sep 2022
paazmaya
0
110
CasperJS Workshop 2015-01-23
paazmaya
0
200
Windows Live sähköpostin käyttäminen Gmail-palvelun kautta
paazmaya
0
2.8k
jQuery - The new wave of JavaScript
paazmaya
0
120
Finland – Coming here and going there
paazmaya
1
69
Nanbudo - Nanbu Kata Book preview
paazmaya
0
940
Nice day for a walk
paazmaya
0
82
Valkoviiksi 7 makers
paazmaya
2
140
Other Decks in Technology
See All in Technology
Agile and AI Redmine Japan 2026
hiranabe
3
430
When Platform Engineering Meets GenAI
sucitw
0
150
ACE-Step-1.5で見る 音楽生成AIのしくみと“破綻だけ直す”Retake機能の開発【zennfes spring 2026 登壇資料】
personabb
1
550
Comment regagner la souveraineté de vos données tout en étant payé grâce à Nostr !
rlifchitz
0
140
新しいUbuntu/GNOMEが使いたいからXからWaylandへ移行頑張ってるの巻 2026-06-20
nobutomurata
0
160
【セミナー資料】Claude Code をセキュアに使うための考え方と設定の勘どころ / Claude Code Webinar 20260616
masahirokawahara
2
440
AWS Security Hub CSPMの成功・失敗体験
cmusudakeisuke
0
450
インシデントレスポンス演習 I / Incident Response Exercise I
ks91
PRO
0
110
iAEONの段階的リアーキテクト戦略 / iAEON's_Gradual_Re-architecture_Strategy
aeonpeople
0
240
ザ・データベース、MySQL ~ OSC 2026 Sendai ~
sakaik
0
170
現場のトークンマネジメント
dak2
1
160
起点・思考・出力で分解する 〜PM業務の自動化設計〜
kazu_kichi_67
0
250
Featured
See All Featured
Performance Is Good for Brains [We Love Speed 2024]
tammyeverts
12
1.7k
Bash Introduction
62gerente
615
220k
Jess Joyce - The Pitfalls of Following Frameworks
techseoconnect
PRO
1
170
The Curse of the Amulet
leimatthew05
1
13k
Are puppies a ranking factor?
jonoalderson
1
3.6k
Skip the Path - Find Your Career Trail
mkilby
1
150
From Legacy to Launchpad: Building Startup-Ready Communities
dugsong
0
230
Stop Working from a Prison Cell
hatefulcrawdad
274
21k
Sharpening the Axe: The Primacy of Toolmaking
bcantrill
46
2.9k
The Spectacular Lies of Maps
axbom
PRO
1
820
The Curious Case for Waylosing
cassininazir
1
400
Chasing Engaging Ingredients in Design
codingconduct
0
220
Transcript
Responsive use of
So far the images have been somewhat static
HTML 4 required to use src and alt
XHTML required a closure
HTML5 introduced new properties
Why not ?
srcset Descriptor defines the width of the image (w) or
the pixel ratio (x)
srcset width use case Usually used when the image has
dynamic size
srcset pixel density use case Usually used when the image
is used in a fixed layout
None
None
None
srcset - benefit & problem
sizes “If the srcset attribute is present, the sizes attribute
may also be present”
sizes examples First matched, first served. Default:
None
srcset & sizes - only benefit
Pixel density matters
3x
Quiz When srcset is unsupported by the given browser, which
image from the example markup below will be downloaded?
What problems does this bring? Duplication of media queries from
styles to markup, hence semantics mixed
What problems does this solve? Browser will download only the
images that are best fitting to the given use case, hence better use bandwidth
What problems does this solve? Developer can leave the calculations
of which image to use in a given case to the browser
Would you like to know more? Please see the talk
“Responsive images are coming to a browser near you” by Yoav Weiss at VelocityConf 2014 youtube.com/watch?v=GC3VgcltKKI
More further reading Please also see the in depth post
by Eric Portis about the topic: ericportis.com/posts/2014/srcset-sizes
Thank you I am Jukka Paasonen, a Responsive Consultant at
Siili Solutions