Skip to content

Commit

Permalink
added amp-img example with fallback attribute (#10122)
Browse files Browse the repository at this point in the history
  • Loading branch information
luciovilla authored and timneutkens committed Jan 16, 2020
1 parent 80ed74b commit 31597bb
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions examples/amp/pages/index.js
Expand Up @@ -18,6 +18,22 @@ export default () => {
<h1>The Cat (AMP-first Page)</h1>
<Byline author="Dan Zajdband" />
<p className="caption">Meowwwwwwww</p>
<amp-img
alt="Mountains"
width="550"
height="368"
layout="responsive"
src="https://amp.dev/static/inline-examples/images/mountains.webp"
>
<amp-img
alt="Mountains"
fallback=""
width="550"
height="368"
layout="responsive"
src="https://amp.dev/static/inline-examples/images/mountains.jpg"
></amp-img>
</amp-img>
<p>
Cat ipsum dolor <a href={isAmp ? '/dog?amp=1' : '/dog'}>sit amet</a>,
eat grass, throw it back up but refuse to leave cardboard box or groom
Expand Down

0 comments on commit 31597bb

Please sign in to comment.