How can I catch when a user clicks on a marker? I’m adding markers to a map for the user to find, like a treasure hunt. When a user touches a treasure I want to show them more details. My app uses SDK 5.1.5.
Here is a code sample that shows how to make a marker clickable:
const markerTemplate = `
<div class="marker">
<p>It's a Marker!</p>
</div>`;
mapView.Markers.add(nodeOrCoordinate, markerTemplate
{ interactive: true });
Interactive markers were added in Mappedin SDK for React-Native version v5.22.0, so you will need to update the SDK version to use this.