我想在地图上显示传单 MarkerCluster,问题在于从 GeoJSON 检索数据:
{
"type": "FeatureCollection",
"features":
[
{
"type": "Feature",
"id": "sto",
"properties": {
"name": "Stoke"
},
"geometry": {
"type": "Point",
"coordinates": [
-0.0731,
51.5615
]
}
},
{
"type": "Feature",
"id": "dal",
"properties": {
"name": "Dalston"
},
"geometry": {
"type": "Point",
"coordinates": [
-0.070,
51.545
]
}
},
{
"type": "Feature",
"id": "wan",
"properties": {
"name": "Wandsworth"
},
"geometry": {
"type": "Point",
"coordinates": [
-0.1924,
51.4644
]
}
},
{
"type": "Feature",
"id": "batt",
"properties": {
"name": "Battersea"
},
"geometry": {
"type": "Point",
"coordinates": [
-0.1677,
51.4638
]
}
}
]
}
我试图在两个示例中重现相同的情况:
有人知道为什么第二个示例中的 MarkerCluster 没有显示吗?我错过了geojson中的一些属性吗?