54403

Was default_marker removed from mapbox-gl.js

Question:

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.

Answer1:

Apologies for the change, ongle! We've recently worked to <a href="https://github.com/mapbox/mapbox-gl-styles/issues/241" rel="nofollow">standardize the icons</a> <a href="https://github.com/mapbox/mapbox-gl-styles#standard-icons" rel="nofollow">available across all the Mapbox styles</a> 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 <a href="https://www.mapbox.com/help/custom-markers/" rel="nofollow">upload your own marker image per this guide</a>.

Recommend

  • How to cross-out word if not active in the JS tree?
  • Issue with dojo confirm dialog widget called from jsp
  • Update slice of tensor in tensorflow
  • SearchResult in Java
  • How to write this polyvariadic composition function in Haskell?
  • BSD md5 vs GNU md5sum output format?
  • Django cascade save?
  • How to increase WebFlux WebClient's throughput?
  • multiple file download using SkyDrive API
  • .HTML5 alternative for frames with 1 fixed (menu) column
  • Laravel Blade - custom method for html block?
  • Retrieving Value from Row in Struts2 Table While using Displaytag
  • macOS Swift Safari-like tabs
  • How to find files not tracked by git and then rsync those files?
  • Android BottomNavigationView with Badge [closed]
  • Iterating through a folder using batch script
  • Efficiently comparing generated code between two Git revisions of the source
  • ASP.Net MVC entity framework submit model, then open new model in edit page
  • How exactly do you use json_decode to pass a javascript array to php?
  • Access to database zend framework
  • Django REST framework - HyperlinkedRelatedField with additional parameter
  • Ajax call on Multiple selection in Select box
  • java.io.FileNotFoundException: Could not open ServletContext resource [/WEB-INF/SpringDispatcher-ser
  • Add font awesome icon to custom add to cart button in Woocommerce 3
  • Google Spreadsheet Script to Blink a range of Cells
  • How do I add a mouse over tooltip to an Image using .DrawImage()
  • Unity3d lost directional light shadows after generate assetBundle (.unity3d file)
  • Python Flask - GUI for client
  • How to mutate multiple variables without repeating codes?