Skip to content

feature request: use route info from url #11601

@KiaraGrouwstra

Description

@KiaraGrouwstra

For a URL /products/123, can we grab and use that 123 from the URL to fetch and display the corresponding data?

Potential advantages:

  • reuse the template, handling user clicks on related products with a setState.
  • a single static asset could be used across the different items. I'm hoping this would facilitate combining AMP with a serverless architecture.
  • skip another page load when navigating to a different item.
  • keep logic dynamic to reuse in the PWA, where I fear hard navigation would result in loss of application state (AMP.setState stuff).

(earlier posted on SO, here reworded as a feature request as afaik it seems to be missing.)

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions