AMP All In One


AMP All In One

Accelerated Mobile Pages

AMP 是一个网络组件框架,可以轻松创建用户至上的 网站 / 故事 / 广告 / 电子邮件.

&



  
    
    
    Hello, AMPs
    
    
    
    
  
  
    

Welcome to the mobile web

AMP Boilerplate Generator



  
    
    
    
    
    
    
    
    

    
    My AMP Page
  
  
    

Hello World

https://amp.dev/boilerplate/

test




  
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    

    
    My AMP Page
    
    
  
  
    

Hello World

This browser does not support the video element.

https://amp.dev/documentation/components/amp-install-serviceworker#attributes



installing service worker


https://github.com/ampproject/amp-sw/

importScripts('https://cdn.ampproject.org/sw/amp-sw.js');

AMP_SW.init({
  // ...
});

AMP 工作原理

schema & JSON-LD

application/ld+json

针对大多数搜索引擎使用 Schema.org

Schema.org 提供开放式词汇,可为各类内容添加元数据。

对于 AMP,在上下文中有意义的属性包括特定类型的内容(例如“新闻报道”)、标题、发布日期和相关的预览图片。


https://schema.org/docs/full.html

https://amp.dev/zh_cn/documentation/guides-and-tutorials/optimize-and-measure/discovery/?format=websites#针对大多数搜索引擎使用-schema.org

https://validator.schema.org/

https://validator.schema.org/#url=https%3A%2F%2Fwww.cnblogs.com%2Fxgqfrms%2Fp%2F16213451.html

https://validator.schema.org/#url=https%3A%2F%2Fcdn.xgqfrms.xyz%2FAMP%2Findex.html

富媒体搜索结果测试 - Google Search Console

https://search.google.com/test/rich-results/result?id=RPQsjOXseTfcD4bOouQISw

https://search.google.com/test/rich-results/result/r%2Farticles?id=RPQsjOXseTfcD4bOouQISw

https://www.xgqfrms.xyz/amp/index.html

demo

https://cdn.xgqfrms.xyz/AMP/index.html

https://www.xgqfrms.xyz/index.html
https://www.xgqfrms.xyz/amp/index.html

refs


Flag Counter

?xgqfrms 2012-2020

www.cnblogs.com/xgqfrms 发布文章使用:只允许注册用户才可以访问!

原创文章,版权所有??xgqfrms, 禁止转载 ???,侵权必究??!