react-places-autocomplete
react-places-autocomplete copied to clipboard
Search by addres or postal_code not working
I need to search by address or posta_code, at the same time. I have something like this
<PlacesAutocomplete
value={this.props.address}
onChange={this.props.onHandleChange}
onSelect={this.props.onSelect}
searchOptions={{
componentRestrictions:{ country: selectedCountry},
types:["address", "(regions)"]
}}
>
but it returns
predictions: [] status: "INVALID_REQUEST"
with only address works for address, but when I try with regions it return for example the postal code from london but I need a postal code more precise.
This are all my dependencies and versions
"dependencies": {
"axios": "^0.21.1",
"final-form": "^4.20.1",
"i18next": "^19.8.4",
"jquery": "^3.5.1",
"react": "^16.13.1",
"react-dom": "^16.13.1",
"react-final-form": "^6.5.2",
"react-i18next": "^9.0.10",
"react-intl": "^5.10.16",
"react-places-autocomplete": "^7.3.0",
"react-redux": "^7.2.1",
"react-select2-wrapper": "^1.0.4-beta6",
"react-tooltip": "^4.2.13",
"redux": "^4.0.5",
"redux-form": "^8.3.6",
"redux-saga": "^1.1.3"
}