AMP

AMP 组件目录

AMP HTML 库由一个基本的运行时组成,它将 AMP 的核心功能带到您的页面。如果您想添加其他功能,可以使用一个或多个现成的 AMP 组件来实现。它们被分类为

内置 包含在基本库中的组件,例如 amp-imgamp-pixel
扩展 基本库的扩展,必须作为自定义元素显式包含在文档中。
实验性 已发布但尚未准备好广泛使用的组件。

突出显示的组件

按类别筛选

动态内容

amp-autocomplete
Suggests completed results corresponding to the user input as they...
amp-bind
Allows elements to mutate in response to user actions or data...
amp-form
Allows you to create forms to submit input fields in an AMP document.
amp-img
Replaces the HTML5 img tag.
amp-layout
A generic, multi-purpose container element that brings AMP's...
amp-list
Dynamically downloads data and creates list items using a template.
amp-mustache
Allows rendering of Mustache templates.
amp-selector
Represents a control that presents a menu of options and lets the...

媒体

amp-anim
Manages an animated image, typically a GIF.

展示

amp-fit-text
扩大或缩小字体大小以使内容适应给定的空间。
amp-timeago
通过将日期格式化为多久以前(例如...)来提供模糊的时间戳。