mapbox / mapbox/mapbox-gl-draw
MapboxDraw.modes is undefined
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 1.1k
- Forks
- 612
- Avg merge
- 8d 9h
- Merged PRs (30d)
- 5
Description
**mapbox-gl-js version**: v0.39.1
**mapbox-gl-draw version**: v0.19.0
### Steps to Trigger Behavior
1. `console.log(MapboxDraw.modes)`
### Expected Behavior
[API](https://github.com/mapbox/mapbox-gl-draw/blob/master/docs/API.md) states that
> modes, Object: over ride the default modes with your own. MapboxDraw.modes can be used to see the default values
### Actual Behavior
`MapboxDraw.modes` is undefined
### Side notes
I'm using both mapboxgl and mapboxgldraw from a CDN in the browser, using globals from `window`
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reading the modes section of docs/API.md and reproduce console.log(MapboxDraw.modes) with the reported CDN globals and versions. Compare the documented API with the actual browser behavior; done means the documented access to default modes works or the documentation accurately reflects the supported API.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript
- Domain
- api
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 45/100