Skip to content

Tag: mapbox

determining circle-color with nested expressions

I use a GeoJSON as my source, where every entity has a state. I want to draw circles for every entity, where the circle color is based on the state, and whether the circle has been clicked or not. Determining the “clicked-state” is done via setFeatureState() where a feature receives the “cli…

mapbox change source property

I want to make a cluster layer with mapbox, yes I made it :D. But I want to be able to turn it off So I’m making a source Now I’m able to set the data: After this I am setting the layers for the clusters and circles. Now clustering is working But now: How can I set the cluster: