Upgrade to Pro — share decks privately, control downloads, hide ads and more …

プログラマがAMPと付き合う上で 知っておくべきこと

プログラマがAMPと付き合う上で 知っておくべきこと

PWAと一緒に語られる事が増えてきたAMP
実はAMPはPWAと組み合わせないでも単体で利用できる技術です
このスライドではAMPとは何か、どうやって作るのか、何に注意すべきかといった概要をまとめています

Hirokatsu Endo

April 14, 2018
Tweet

More Decks by Hirokatsu Endo

Other Decks in Technology

Transcript

  1. <!doctype html> <html ⚡> <head> <meta charset="utf-8"> <script async src="https://cdn.ampproject.org/v0.js"></script>

    <title>Hello AMP world</title> <link rel="canonical" href="hello-world.html"> <meta name="viewport" content=“width=device-width,minimum- scale=1,initial-scale=1"> <style amp-boilerplate>body{-webkit-animation:-amp-start 8s steps(1,end) 0s 1 normal both;-moz-animation:-amp-start 8s steps(1,end) 0s 1 normal both;-ms-animation:-amp-start 8s steps(1,end) 0s 1 normal both;animation:-amp-start 8s steps(1,end) 0s 1 normal both}@-webkit-keyframes -amp-start{from{visibility:hidden} to{visibility:visible}}@-moz-keyframes -amp- start{from{visibility:hidden}to{visibility:visible}}@-ms-keyframes - amp-start{from{visibility:hidden}to{visibility:visible}}@-o-keyframes -amp-start{from{visibility:hidden}to{visibility:visible}}@keyframes - amp-start{from{visibility:hidden}to{visibility:visible}}</ style><noscript><style amp-boilerplate>body{-webkit-animation:none;- moz-animation:none;-ms-animation:none;animation:none}</style></ noscript> </head> <body> <h1>Hello AMP World!</h1> </body> </html>
  2. <!doctype html> <html ⚡> <head> ... <script async custom-element=“amp-youtube" src=“https://cdn.ampproject.org/v0/amp-youtube-0.1.js">

    </script> ... </head> <body> ... <amp-youtube data-videoid="WrpkFROqR0Q" layout="responsive" width="560" height="315"> </amp-youtube> ... </body> </html>
  3. <!doctype html> <html ⚡> <head> ... <script async custom-element=“amp-twitter" src=“https://cdn.ampproject.org/v0/amp-twitter-0.1.js">

    </script> ... </head> <body> ... <amp-twitter data-tweetid=“638793490521001985" layout="responsive" width="500" height="583"> </amp-twitter> ... </body> </html>