viewer.dataSources.add(Cesium.GeoJsonDataSource.load(‘villains.geojson’, {
stroke: Cesium.Color.HOTPINK,
fill: Cesium.Color.PINK,
strokeWidth: 3,
markerSymbol: ‘park’,
clampToGround: true
}));
``
If s it possible to add an image to a popup for an entity created from a GeoJSON? Mapbox’s documentation says it’s possible to do it by adding an tag to the description value in the GeoJSON file, but every time I do that in Cesium, the markers disappear.
, , and other tags work fine. Here’s the code I’m using:
and here’s the contents of villains.geojson
{
“type”: “FeatureCollection”,
“features”: [
{
“type”: “Feature”,
“geometry”: {
“type”: “Point”,
“coordinates”: [ -70.935078,44.556036 ]
},
“properties”: {
“title”:“The Riddler”,
“description”:“
here is a descriptionand another line”
}
},
{
“type”: “Feature”,
“geometry”: {
“type”: “Point”,
“coordinates”: [ -70.869061,44.572023 ]
},
“properties”: {
“title”:“Felonius Gru”,
“description”:“This is a second description”
}
}
]
}
``