olahol / iso-3166-2.js

Lookup information about ISO-3166-2 subdivisions
MIT License
108 stars 41 forks source link

wish: allow lookup by name #1

Closed markstos closed 10 years ago

markstos commented 10 years ago

I would like to be able to lookup ("US","Indiana") and have have the state code "IN" included as part of the result set.

markstos commented 10 years ago

Great, thanks!

markstos commented 10 years ago

I've tried this now, and have some more feedback. I see that I can search by ("US","Indiana") now, but the region code currently returned is "US-IN".

Would it be possible to add a new 'regionCode' key that contains just 'IN' in this case so it doesn't have to be parsed out? I already know that the country code is "US", since I just passed it in.

Thanks,

Mark
olahol commented 10 years ago

You are right I missed that you only wanted the region code, I've added regionCode to the output in version 0.2.1.

markstos commented 10 years ago

Thanks!

On Wednesday, April 2, 2014, Ola Holmström notifications@github.com wrote:

You are right I missed that you only wanted the region code, I've added regionCode to the output in version 0.2.1.

Reply to this email directly or view it on GitHubhttps://github.com/olahol/iso-3166-2.js/issues/1#issuecomment-39399638 .

Mark Stosberg
Senior Systems Engineer
RideAmigos