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
Serving WebP images via content negotiation
Search
Szymon Nowak
November 04, 2015
Programming
1
87
Serving WebP images via content negotiation
Lightning talk from meet.js meetup 11/2015
Szymon Nowak
November 04, 2015
Tweet
Share
More Decks by Szymon Nowak
See All by Szymon Nowak
meet.js Katowice - ES6 Promises 101
szimek
1
230
GDG DevFest 2015 Poland - How to grow your own Babel fish
szimek
0
64
JSConf EU 2015 - How to grow your own Babel fish
szimek
0
330
Other Decks in Programming
See All in Programming
The Past, Present, and Future of Enterprise Java
ivargrimstad
0
600
コントリビューターによるDenoのすゝめ / Deno Recommendations by a Contributor
petamoriken
0
200
Oxlint JS plugins
kazupon
1
980
それ、本当に安全? ファイルアップロードで見落としがちなセキュリティリスクと対策
penpeen
7
3.9k
Architectural Extensions
denyspoltorak
0
290
AI時代のキャリアプラン「技術の引力」からの脱出と「問い」へのいざない / tech-gravity
minodriven
21
7.3k
15年続くIoTサービスのSREエンジニアが挑む分散トレーシング導入
melonps
2
220
生成AIを使ったコードレビューで定性的に品質カバー
chiilog
1
270
なるべく楽してバックエンドに型をつけたい!(楽とは言ってない)
hibiki_cube
0
140
izumin5210のプロポーザルのネタ探し #tskaigi_msup
izumin5210
1
130
フロントエンド開発の勘所 -複数事業を経験して見えた判断軸の違い-
heimusu
7
2.8k
Raku Raku Notion 20260128
hareyakayuruyaka
0
340
Featured
See All Featured
B2B Lead Gen: Tactics, Traps & Triumph
marketingsoph
0
56
Done Done
chrislema
186
16k
Imperfection Machines: The Place of Print at Facebook
scottboms
269
14k
Neural Spatial Audio Processing for Sound Field Analysis and Control
skoyamalab
0
170
How to Think Like a Performance Engineer
csswizardry
28
2.4k
The Impact of AI in SEO - AI Overviews June 2024 Edition
aleyda
5
730
Marketing Yourself as an Engineer | Alaka | Gurzu
gurzu
0
130
For a Future-Friendly Web
brad_frost
182
10k
How Fast Is Fast Enough? [PerfNow 2025]
tammyeverts
3
450
Lightning Talk: Beautiful Slides for Beginners
inesmontani
PRO
1
440
AI Search: Where Are We & What Can We Do About It?
aleyda
0
7k
The Pragmatic Product Professional
lauravandoore
37
7.1k
Transcript
SERVING WEBP IMAGES VIA CONTENT NEGOTIATION SZYMON NOWAK @SZIMEK
366K
[email protected]
248K
[email protected]
198K
[email protected]
81K
[email protected]
173K
[email protected]
81K
[email protected]
FIREFOX Accept: image/png,image/*;q=0.8,*/*;q=0.5
CHROME Accept: image/webp,image/*,*/*;q=0.8
NGINX if ($http_accept ~* "webp") { set $webp_accept "true"; }
NGINX if ($webp_accept = "true") { rewrite (.*) $1.webp break;
}
NGINX add_header Vary Accept;
https://www.igvita.com/2013/05/01/deploying- webp-via-accept-content-negotiation/
OR USE PICTURE ELEMENT https://developer.mozilla.org/en-US/docs/Web/ HTML/Element/picture
OR USE SERVICE WORKERS http://deanhume.com/Home/BlogPost/service- workers--dynamic-responsive-images-using- webp-images/10132/