javascripteventsdom-eventsamp-htmlamp-story

How do events and event objects work in amp-story? Is there a full list of AMP events and actions? Is there a full list for amp-story?


https://www.oreilly.com/library/view/amp-building-accelerated/9781786467317/d236e811-756a-4ffb-8f8b-712a34b8f751.xhtml

So far, the only event we've seen is tap, and the only actions we've seen are open, close, and dismiss. You might be curious about what others are available. While tap applies to all elements, most events in AMP are specific to particular elements. For example, forms have submit , submit-success, and submit-error events, and input elements have a change event , while amp-selector has a select event, to name a few. There are many more; for a full list of AMP events and actions, see Appendix B, Actions and Events.

Event Objects

When an event occur in HTML, the event belongs to a certain event object, like a mouse click event belongs to the MouseEvent object.

The Event Object

All event objects are based on the Event Object, and inherits all of it's properties and methods

common event objects


Solution

  • The full list for AMP generally can be found in the AMP Actions and Events documentation.

    For AMP stories, there are currently no events supported.