Donald Byrd
Donald Byrd

Reputation: 7778

Was default_marker removed from mapbox-gl.js

I am trying to use the default_marker and/or secondary_marker in mapbox-gl.js however it appears they have been removed from the sprite.json in streets-v9 (probably v8 too). I've found a working example in streets-v7 where they were part of the sprite.json/sprit.png, but they are gone now.

How can I get these back or what is the new replacement? I've gone through the new sprint.png but I don't see anything similar.

Upvotes: 1

Views: 391

Answers (1)

Lucas Wojciechowski
Lucas Wojciechowski

Reputation: 3802

Apologies for the change, ongle! We've recently worked to standardize the icons available across all the Mapbox styles which, unfortunately, required some breaking changes.

The closest replacement to default_marker is marker-15. The appearance of this marker will be different per style.

You may also choose to upload your own marker image per this guide.

Upvotes: 3

Related Questions