mapbox / mapbox-sdk-js

A JavaScript client to Mapbox services, supporting Node, browsers, and React Native
Other
714 stars 184 forks source link

forwardGeocode option 'countries' inconsistent with mapbox docs 'country' #326

Open davidfurlong opened 5 years ago

davidfurlong commented 5 years ago

Seems rather unnecessarily confusing if intentional

https://docs.mapbox.com/api/search/#forward-geocoding

https://github.com/mapbox/mapbox-sdk-js/blob/c0ae1604f9f05a91335c70a8535597e1517c1acb/docs/services.md#forwardgeocode

andrewharvey commented 4 years ago

I agree it's confusing, but I think what we have here in the SDK using countries and accepting an array is better, so I'd rather we keep using countries here.

Perhaps the API could be updated to accept countries, with country still accepted for compatibility.