Problem: Slow performance when editing vertices of a complex geometry with JavaScript API


The Move and Edit Vertices sample from the ArcGIS API for JavaScript shows how to use the edit toolbar to move and edit vertices. This sample works fine with simple geometry; however, when handling a complex geometry with a large number (thousands) of vertices, browser performance may become slow or unresponsive.


The more complex the geometry is, the more resources the browser will use to render all the vertices because the client renders vertices on the fly. Therefore, performance slows when editing a complex geometry with a large number of vertices.

Solution or Workaround

Performing heavy editing tasks through Web APIs is not recommended. The following tips can improve editing performance:

• Zoom into the geometry.

Because the client renders vertices on the fly, narrowing the extent reduces the number of vertices that need to be drawn. This improves browser performance.

• Simplify the geometry to display fewer vertices.

• Cut the geometry into smaller pieces.