Debugging state with AMP.printState()

You can output the current state to the developer console at any time. This can be useful in debugging an AMP page. To do this, type AMP.printState() into the developer console when in development mode (that is, with #development=1 appended to the page URL):

Displaying AMP state in the browser developer console with AMP.printState()

Get AMP: Building Accelerated Mobile Pages now with the O’Reilly learning platform.

O’Reilly members experience live online training, plus books, videos, and digital content from nearly 200 publishers.