Skip to content
This repository was archived by the owner on Sep 24, 2024. It is now read-only.

Commit 5569a37

Browse files
committed
Updated docs
1 parent 3a9da30 commit 5569a37

File tree

1 file changed

+10
-1
lines changed

1 file changed

+10
-1
lines changed

README.md

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ I have tried to use different Vue Google Autocomplete components, but did not fi
1313
* Load more than one autocompletion inputs (I could not achieve this with existing vue components)
1414
* Getting geolocation data (latitude, longitude) for found address object along with other address data (country, city, state, county, street, house number, zip code). So no need to do additional geocode request on backend side.
1515
* No external dependencies
16-
* You can get access to underlying [PlaceResult object](https://developers.google.com/maps/documentation/javascript/reference#PlaceResult) to get more details about found location.
16+
* You can get access to underlying [PlaceResult object](https://developers.google.com/maps/documentation/javascript/reference#PlaceResult) to get more details about found location. You are able to specify the specific fields you want to fetch from the PlaceResult object.
1717
* You can limit results to specific country or use users geolocation data
1818

1919
## Installation
@@ -93,6 +93,15 @@ Types supported in place autocomplete requests. [More info](https://developers.g
9393

9494
You may find [this example](#correct-usage-of-the-types-parameter) helpful.
9595

96+
97+
#### fields
98+
Type: `Array`
99+
Default: `['address_components', 'adr_address', 'alt_id', 'formatted_address', 'geometry', 'icon', 'id', 'name', 'permanently_closed', 'photo', 'place_id', 'scope', 'type', 'url', 'utc_offset', 'vicinity']`
100+
101+
Set which data fields to return in the PlaceResult from the Google Autocomplete API when the user selects a place. [Google Autocomplete API by default returns all available data fields](https://developers.google.com/maps/documentation/javascript/places-autocomplete#get_place_information) for the selected place, which may result in additional charges and thus the API users might pay for data they don't need. This package sets a sensible default for the fields value, fetching only the Basic Data fields which do not result in any additional charges. If you want to fetch other fields in addition to the default ones, make sure that the array you pass in to the `fields` prop contains the default fields listed above, and not only the additional fields you want to fetch.
102+
103+
Refer to [this page](https://developers.google.com/maps/billing/understanding-cost-of-use#data-skus) for more details on how certain data fields are billed.
104+
96105
#### country
97106
Type: `String`|`Array`
98107
Default: null

0 commit comments

Comments
 (0)