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

Enhancement Request: Getters for Address Components #257

Open
anaxmedia opened this issue Mar 27, 2018 · 1 comment
Open

Enhancement Request: Getters for Address Components #257

anaxmedia opened this issue Mar 27, 2018 · 1 comment

Comments

@anaxmedia
Copy link

Hi there! This API is a amazing and a huge time saver for me. I was wondering if it would be possible to add getters to the location object for the address components returned by Geocoding responses?

Source:
https://developers.google.com/maps/documentation/geocoding/intro#GeocodingResponses

I see you've already added Postal Code (getPostalCode()),

Would it be possible to add: the other components? Google recommends using these to store the formatted address into a database as opposed to actually parsing the formatted_address returned in the response.

Proposed types per Geocoding Responses:

"types" : [ "street_number" ]
"types" : [ "route" ]
"types" : [ "locality", "political" ]
"types" : [ "administrative_area_level_2", "political" ]
"types" : [ "administrative_area_level_1", "political" ]
"types" : [ "country", "political" ]

@bradcornford
Copy link
Owner

Hi there,

Yes, i'll look at getting these implemented in the future. Feel free however to raise a PR for it too =)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants