Edward Mehr
Edward Mehr

Reputation: 661

L.circleMarker on MapBox with options does not work

I am trying to add a circle marker to my MapBox but passed options doesn't do what its supposed to do. I am using following code

    L.mapbox.featureLayer(
        { "geometry": {"type": "Point", "coordinates": [lng , lat]}, "type": "Feature", "properties": {} },
        { pointToLayer: function(feature, latlon) { 
            var marker = L.circleMarker(latlon, {
                radius: 2,
                color: "#ff0000"
            });

            return marker;
        } }
    ).addTo(map);

the radius is set but the color is set to default.

Upvotes: 1

Views: 376

Answers (1)

tmcw
tmcw

Reputation: 11882

This was a bug in Mapbox.js 2.1.8: if you update to 2.1.9, the issue should be resolved.

Upvotes: 1

Related Questions