Clusteredmapview when I pan or drag the map, I need to call web service based on viewport. I am not able to capture pan or drag gesture on this map. Can you please help me out?
Ramana46 opened this issue · 3 comments
Ramana46 commented
Clusteredmapview when I pan or drag the map, I need to call web service based on viewport. I am not able to capture pan or drag gesture on this map. Can you please help me out?
39otrebla commented
Did you try wrapping the component with PanResponder
? Once you detect a drag/pan, you could then get the current map region and do your calcs for resolving it to viewport
.
nschild commented
Is the onRegionChange
event from react-native-maps
exposed to ClusteredMapView`? This would handle zoom as well as pan.
r0b0t3d commented
For pan start event, you can use onPanDrag
.
using onRegionChange
to make a call to web service is a huge performance issue. you can try onRegionChangeComplete
instead.