conveyal / otp.js

OTP Javascript Client & Data Bindings
MIT License
19 stars 20 forks source link

Add support for more geocoders (Nominatim, Pelias, Mapbox) #71

Closed wwared closed 8 years ago

wwared commented 9 years ago

This pull request adds in support for other geocoding services besides ESRI.

Which geocoder to use for reverse geocoding can also be configured in config.js. For normal geocoding, multiple geocoders' results are combined, the same way it was done with the built-in OTP geocoder.

One note: this code doesn't set the city and state properties of the returned object when reverse geocoding. Searching the source tree, it seems no code relies on it (and in fact, it seems to work fine). Not all geocoders return the address in a structured format, so finding this information would be difficult for some geocoders.