Options
All
  • Public
  • Public/Protected
  • All
Menu

The options that can be set on an Autocomplete object.

Hierarchy

  • AutocompleteOptions

Index

Properties

The area in which to search for places.

componentRestrictions?: ComponentRestrictions

The component restrictions. Component restrictions are used to restrict predictions to only those within the parent component. For example, the country.

fields?: string[]

Fields to be included for the Place in the details response when the details are successfully retrieved, which will be billed for. If ['ALL'] is passed in, all available fields will be returned and billed for (this is not recommended for production deployments). For a list of fields see google.maps.places.PlaceResult. Nested fields can be specified with dot-paths (for example, "geometry.location"). The default is ['ALL'].

placeIdOnly?: boolean

Whether to retrieve only Place IDs. The PlaceResult made available when the place_changed event is fired will only have the place_id, types and name fields, with the place_id, types and description returned by the Autocomplete service. Disabled by default.

deprecated

placeIdOnly is deprecated as of January 15, 2019, and will be turned off on January 15, 2020. Use google.maps.places.AutocompleteOptions.fields instead: fields: ['place_id', 'name', 'types'].

strictBounds?: boolean

A boolean value, indicating that the Autocomplete widget should only return those places that are inside the bounds of the Autocomplete widget at the time the query is sent. Setting strictBounds to false (which is the default) will make the results biased towards, but not restricted to, places contained within the bounds.

types?: string[]

The types of predictions to be returned. For supported types, see the developer's guide. If no types are specified, all types will be returned.

Generated using TypeDoc