Page Experience (PX) is a set of ranking signals—including
Core Web Vitals (CWV)—measuring the user experience of interacting with a web page. AMP is a powerful tool which applies many optimizations and best practices automatically on your site, making it easier for you to achieve good page experience for your visitors. The official AMP Plugin, supported by the AMP team, makes it easy to bring the power of AMP to your WordPress site, seamlessly integrating with the normal publishing flow and allowing the use of existing themes and plugins.
https://www.youtube.com/watch?v=s52JNMT59s8&list=PLXTOW_XMsIDRGRr5QDffrvND8Qh1RndFb
For more videos like this, check out the ongoing
AMP for WordPress video series.
该插件的主要功能包括:
- Automate the process of generating AMP-valid markup as much as possible, letting users follow the standard workflows they are used to in WordPress.
- Provide effective validation tools to help users deal with AMP incompatibilities when they happen, including mechanisms for identifying, contextualizing, and resolving issues caused by validation errors.
- Provide development support to make it easier for WordPress developers to build AMP-compatible ecosystem components and build websites and solutions with AMP-compatibility built-in.
- Support the serving of AMP pages to make it easier for site owners to take advantage of mobile redirection, AMP-to-AMP linking, and generation of optimized AMP by default (via PHP port of AMP Optimizer).
- Provide a turnkey solution for segments of WordPress creators to be able to go from zero to publishing AMP pages in no time, regardless of technical expertise or availability of resources.
The official AMP plugin for WordPress is a powerful tool that helps you build user-first WordPress sites, that is, sites that are fast, beautiful, secure, engaging, and accessible. A user-first site will deliver experiences that delight your users and therefore will increase user engagement and the success of your site. And, contrary to the popular belief of being only for mobile sites (it doesn't stand for Accelerated
Mobile Pages anymore!), AMP is a fully responsive web component framework, which means that you can provide AMP experiences for your users on both mobile and desktop devices.
AMP Plugin 受众: 每一个人
此插件可供开发人员和非开发人员用户使用:
- 如果您是开发人员或精通技术的用户,则可以利用 AMP 插件提供的高级开发人员工具来修复您的网站可能存在的验证问题并实现完全的 AMP 兼容性。
- 如果您不是开发人员或精通技术的用户,或者您只是不想处理验证问题和处理开发任务,AMP 插件允许您利用 AMP 兼容的不同配置组装完全兼容 AMP 的站点 组件。 该插件通过在可能的情况下删除无效的 AMP 标记或完全禁止 AMP 页面上的 AMP 不兼容插件来帮助您处理验证问题。
最重要的是,无论您的技术专长如何,AMP 插件都对您有用。
模板模式
官方 AMP 插件使网站所有者能够以不同的方式为其用户提供 AMP,这些方式称为模板模式:标准、过渡和阅读器。 它们之间的区别在于使用的主题数量(一个或两个)和网站版本的数量(非 AMP、AMP)。 每种模板模式都有自己的价值主张,服务于庞大而多样的 WordPress 生态系统中不同场景的需求。 在所有情况下,AMP 插件都在自动生成 AMP 页面以及保持所选 AMP 选项有效方面提供尽可能多的支持。 简而言之,可用的模板模式如下:
Standard Mode: This template mode is the ideal, as there is only one theme for serving requests and a single version of your site: the AMP version. Besides enabling all of your site to be AMP-first, this has the added benefit of reducing development and maintenance costs. This mode is the best choice for sites where the theme and plugins used in the site are fully AMP-compatible. It's also a good option if some components are not AMP-compatible but the site owner has the resources or the know-how to fix them. See our
showcase of sites using Standard mode.
Transitional Mode: In this mode there is also a single theme used, but there can be two versions of each page: AMP and non-AMP. The active theme is used for serving the AMP and non-AMP versions of a given URL. This mode is a good choice if the site uses a theme that is not fully AMP compatible, but the functional differences between the AMP and non-AMP pages are acceptable (due to graceful degradation). In this case, users accessing the site from mobile devices can get the AMP version and get an optimized experience which also retains the look and feel of the non-AMP version. Check out our
showcase of sites using Transitional mode.
Reader Mode: In this mode there are two different themes, one for AMP pages and another for non-AMP pages, and therefore there are also two versions of the site. This mode may be selected when the site is using an AMP-incompatible theme, but the level of incompatibilities is significant without graceful degradation. It's also a good choice if you are not technically savvy (or simply do not want to deal with the incompatibilities) and therefore want simplified and robust workflows that allow you to take advantage of AMP with minimal effort.
在不同的场景中会推荐不同的模式,具体取决于您站点的具体情况和您的角色。 在您配置插件时,它会根据对您网站上使用的主题和插件的评估来建议最适合您的模式。 而且,无论使用何种模式,您都可以选择将网站的全部或部分内容作为 AMP 提供服务。 这为您提供了开始在您的网站上逐步启用 AMP 所需的所有灵活性。
AMP Ecosystem
今天,通过从不断增长的 AMP 兼容生态系统中挑选和选择主题和插件,可以组装由 AMP 插件提供支持的外观精美的用户至上网站。 在这种情况下,AMP 插件充当整个 AMP 内容创建和发布过程的协调者; 它充当验证者和执行者,不仅可以更轻松地获得 AMP 体验,而且可以自信地维护它们。
Many popular theme and plugin developers have taken efforts to support the official AMP plugin. If you are using a theme like Astra or Newspack, or if you are using plugins like Yoast or WP Forms — they will work out of the box! You can see the
growing list of tested themes and plugins.
AMP 开发
Although there is a growing ecosystem of AMP-compatible WordPress components, there is still a ways to go before majority AMP compatibility in the ecosystem. If you are a developer, or you have the resources to pursue development projects, you may want in some cases to develop custom plugin or theme to serve your specific needs. The official AMP plugin can be of great help to you by providing powerful and effective developer tools that shed light into the AMP development process as it is done in WordPress. This includes mechanisms for detailing the root causes of validation issues, the contextual space to understand them properly, and methods to deal with them during the process of achieving full AMP compatibility. Read more about
Developer Tools.
开始
To learn more about the plugin and start leveraging its capabilities to power your AMP publishing workflow, check
the official AMP plugin product site.
If you are a developer, we encourage you to
follow along or
contribute to the development of this plugin on GitHub.
We have put up a comprehensive
FAQ page and extensive documentation to help you start as smoothly as possible.
But if you need some help, we are right here to support you in the plugin's
support forum, as well as through
GitHub issues (for technical bugs and feature requests). And our thriving
AMP Expert ecosystem has indie freelancers to enterprise grade agencies in case you need commercial support!
Version 2.5.1 is a maintenance and security release which fixes a reflected XSS vulnerability when mobile redirection is enabled. For prior affected versions, the fix is backported to new patch releases: v2.0.12, v2.1.5, v2.2.5, v2.3.1, and v2.4.3. These are available in the
WordPress.org Plugin Directory but not on GitHub.
For the plugin’s changelog, please see
the Releases page on GitHub.