mapbox / mapbox/mapbox-gl-geocoder

API.md parameters options.type misleading and incorrect.

Open
#317 3 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

auto-triaged docs improvement
Dominant language
JavaScript
Stars
388
Forks
181
PR merge metrics
No merged PRs in 30d

Description

The [API.md](https://github.com/mapbox/mapbox-gl-geocoder/blob/master/API.md#parameters) needs updating.
Under `options.types` it states:

> If reverseGeocode is enabled, you should specify one type. If you configure more than one type, the first type will be used.

This is misleading and incorrect. If you specify only one type and there are no results for that type you will get the message "No results found". You can and should specify multiple types in order of preference.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Open API.md and read the parameters section for options.types. Update the misleading reverse-geocoding guidance to reflect that multiple types can be specified in preference order and that a single type may produce no results; done means the documentation matches the described behavior.

Written by the indexing model from the issue text.

Assessment

Domain
documentation
Issue type
Documentation
Difficulty
1/5
Estimated time
Under an hour
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
55/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.