Controls

Add interactive controls to your map for zoom, compass, location, and fullscreen.

The MapControls component provides a set of interactive controls that can be positioned on any corner of the map.

Basic Controls

Show zoom, compass, geolocation, and fullscreen buttons using the showZoom, showCompass, showLocate, and showFullscreen props.

Scale Bar

Add a real-world scale indicator with showScale. The scale bar updates as you zoom in and out and is always rendered at the bottom-left of the map.