File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1- <! doctype html>
2- <html lang =" en " >
3- <head >
4- <meta charset="utf-8">
5- <title>html boilerplate</title>
6-
7- <!-- style -->
8- <link rel="icon" href="icon.png">
9- <meta name="viewport" content="width=device-width">
10- <link rel="stylesheet" href="css/normalize.css">
11- <link rel="stylesheet" href="css/examples/demo.css">
12-
13- <!-- install -->
14- <link rel="manifest" href="manifest.webmanifest">
15- <meta name="msapplication-TileColor" content="#123456">
16- <meta name="msapplication-square150x150logo" content="images/icons/150.png">
17- <meta name="apple-mobile-web-app-capable" content="yes">
18- <meta name="mobile-web-app-capable" content="yes">
19-
20- <!-- prerender -->
21- <link rel="prerender" href="x.html">
22- </head >
23- <body >
1+ # ` <picture> `
242
25- <p>Drink water</p>
26-
3+ ## Use case
274
28- <script src="bundle.js"></script>
29- </body >
30- </html >
5+ Provide the user-agent many image options, letting it decide the one that fits best.
6+
7+ An example where a high resolution image will be downloaded (and used) on wide enough devices.
8+
9+ ```
10+ <picture class="">
11+ <source srcset="image-high-resolution.jpg" media="(min-width: 992px)">
12+ <img class="" src="image-low-resolution.jpg" alt="">
13+ </picture>
14+ ```
15+
16+ ## Fallback
17+
18+ In case the element is not supported the <img > inside will always be used.
You can’t perform that action at this time.
0 commit comments