- AMP:Building Accelerated Mobile Pages
- Ruadhan O'Donoghue
- 104字
- 2021-07-08 10:03:59
Including the AMP-JS library
The very first step in converting any page to AMP will be to include the AMP-JS library in the page. This is an important first step since the AMP library includes development tools that will guide us as we build our AMP pages.
To include the AMP-JS library, simply add the following line within the <head> tag of your markup:
<script async src="https://cdn.ampproject.org/v0.js"></script>
If you open your developer tools console in any modern browser, you should see a line of AMP-specific output:
Powered by AMP HTML
This means the AMP-JS library has loaded and our journey to ride the AMP lightning has truly begun!
推薦閱讀
- Java面向對象思想與程序設計
- C和C++安全編碼(原書第2版)
- Scratch真好玩:教小孩學編程
- React.js Essentials
- 數據結構(C語言)
- 數據結構習題解析與實驗指導
- Python深度學習:模型、方法與實現
- 微信小程序全棧開發技術與實戰(微課版)
- Learning Apache Cassandra
- Flowable流程引擎實戰
- 區塊鏈項目開發指南
- Android Studio開發實戰:從零基礎到App上線 (移動開發叢書)
- Clojure High Performance Programming(Second Edition)
- 現代CPU性能分析與優化
- Getting Started with hapi.js