Skip to content

Autocomplete / suggestion field support in amp-form (enhancement) #6625

@fliptheweb

Description

@fliptheweb

Short description of your issue:

Implementation of autocomplete field in AMP.

Long description:

My company tries to reimplement rich js form to AMP version.
We have a autocomplete field (like react-autocomplete, jquery UI autocomplete, whatever) and I want to use the same functionality in AMP version.
Features:
– fetch remote JSON by XHR;
– custom render with amp-mustache;
– standard HTML validation.

For example:

<amp-autocomplete
    action-xhr="//api.com/search?term=search_term"
    name="origin"
    class="suggestions"
    placeholder="Choose your origin city"
    required />

<template type="amp-mustache">
  <div class="suggestions-item" amp-value="">{{text}} ({{iata}})</div>
</template>

Is it possible to implement autocomplete in AMP? Let's discuss.

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions