mapbox / mapbox/mapbox-gl-draw

when the frame width is 400px,the demo for "Show drawn polygon area" perf good , but change the width to 700 or more ,it becomes super slow.

Open
#908 3 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

performance rendering
Dominant language
JavaScript
Stars
1.1k
Forks
612
Avg merge
8d 9h
Merged PRs (30d)
5

Description

**mapbox-gl-js version**: v1.2.0
**mapbox-gl-draw version**: v1.0.9
same as demo

### Steps to Trigger Behavior

1. copy the code of demo in this page (https://docs.mapbox.com/mapbox-gl-js/example/mapbox-gl-draw/) ,and paste in your local, save as html.
2. when you drawing polygon ,it perfroms slowly, not soomthly as demo shows
3. and also drag the map , it is slow too.

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

Reproduce the issue with the Mapbox GL Draw demo at the linked example, using mapbox-gl-js v1.2.0 and mapbox-gl-draw v1.0.9, first drawing at 400px and then at 700px or wider. Profile polygon drawing and map dragging to locate the slowdown; done means the reported large-width interaction is no longer noticeably slow.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript
Domain
frontend, performance
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.