You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Mapbox GL JS v3.9+ adds a new Interactions API (map.addInteraction() / map.removeInteraction()) for handling events declaratively on layers, featuresets, or the whole map.
This would remove the map.on/off boilerplate and make interactions reactive with props/state.
Proposal
It’d be great if react-map-gl exposed a simple component/hook for this, e.g.: