Skip to content
This repository has been archived by the owner on Oct 10, 2018. It is now read-only.

Validate that output buffer works as expected each template on render and correctly identifies AMP components #62

Closed
postphotos opened this issue Feb 2, 2018 · 1 comment
Projects
Milestone

Comments

@postphotos
Copy link

AC1: The rendered PHP output from each page template (index.php, single.php, archive.php, etc.) should be output buffered to control what specific output is sent in the response from the templates.

  • Because PHP parsing is piecemealed and complex, theme markup rendering can become more efficient if rendered using output buffering.
  • As a result of working shortcodes and page templates, and components (sidebar.php, comments.php)

AC2: The buffered output should be modified to remove elements and attributes that are invalid AMP.

  • <script> tags, for example, should not renderable from widget or content areas on the front end.

AC3: Each output buffer logic should play nicely with the the AMP plugin to filter standard HTML markup into valid, AMP-compatible markup. Standard HTML output by the theme should get converted over to AMP equivalents, such as using action-xhr attribute for POST forms instead of action attributes.

AC4: As a result of this template output buffering, AMP pages should not have visual or functional regression compared to their HTML versions in support of rendering AMP canonical pages.

@MackenzieHartung MackenzieHartung added this to the v0.1 milestone Feb 5, 2018
@kopepasah
Copy link
Contributor

@postphotos I believe this issue should be added to the plugin, as there is nothing to do theme wise to verify this markup, all the parsing happens in the plugin.

@ThierryA ThierryA added this to Ready for Merging in v0.1 Mar 8, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
v0.1
Ready for Merging
Development

No branches or pull requests

4 participants