Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add the restriction for the particular country #55

Closed
VivekaLogu opened this issue Apr 9, 2020 · 1 comment
Closed

Add the restriction for the particular country #55

VivekaLogu opened this issue Apr 9, 2020 · 1 comment

Comments

@VivekaLogu
Copy link

VivekaLogu commented Apr 9, 2020

In which file we have to add the options to restrict the particular country on angular 8

@sbelaustegui
Copy link

sbelaustegui commented Oct 7, 2020

@VivekaLogu you have to pass it throw HTML tag. something like this:

<input ngx-google-places-autocomplete [options]="autocompleteOptions" type="text" aria-label="Number" placeholder="Dónde?" matInput (onAddressChange)="handleAddressChange($event)" />

Then in the .ts you declared the object like this:
autocompleteOptions = { componentRestrictions: { country: 'AR' } };

@skynet2 skynet2 closed this as completed Nov 3, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants