I try to implement clustering in Mapbox for iOS and literally use this example from the Mapbox website
It works fine, but I would like to use simple MGL notes to place on the map and link them if they is too close.
I read here that MGLShapeSource not only accepts external geoJSON, but other sources, such as polylines and annotations. But when I add it to notes, no grouping occurs, I see only many of my markers from my annotation event:
la source = MGLShapeSource (identify: "clusteredParkings, forms: annotationsArray, options: [.clustered: true, .clusterRadius: 20] )
When I switch source back to geoJSON, it works again for clusters.
Btw there are no errors or warnings.
What am I doing wrong? Does anyone have a working example of Mapbox clustering with MGLAnnotations rather than geoJSON source file?