I\'m trying to set up a clustered map on mapbox, like http://leaflet.github.io/Leaflet.markercluster/example/marker-clustering-realworld.388.html
But their example uses
Create a geoJson layer and then add that layer to MarkerCluster:
var markers = new L.MarkerClusterGroup();
var geoJsonFeature = = {
"type": "Feature",
"properties": {
"name": "Coors Field",
"amenity": "Baseball Stadium",
"popupContent": "This is where the Rockies play!"
},
"geometry": {
"type": "Point",
"coordinates": [-104.99404, 39.75621]
}
};
var geoJsonLayer = L.geoJson(geoJsonFeature);
markers.addLayer(geoJsonLayer);
map.addLayer(markers);