mapbox-gl
3.34.2 · 3 Nov 2026SEE LICENSE IN LICENSE.txt6M / weekRepositoryHomepagenpmAtom feed
0.54.1 is the newest release of 0.40.x.
In short
2 breaking10 new18 fixed
- breaking
Map#addImagenow requires the image as anHTMLImageElement,ImageData, or object withwidth,height, anddataproperties with the same format asImageData. It no longer accepts a rawArrayBufferViewin the second argument andwidthandheightoptions in the third argument. - breaking
canvassources now require acontextTypeoption specifying the drawing context associated with the source canvas. #5155
Release note
:warning: Breaking changes
- breaking
Map#addImagenow requires the image as anHTMLImageElement,ImageData, or object withwidth,height, anddataproperties with the same format asImageData. It no longer accepts a rawArrayBufferViewin the second
argument andwidthandheightoptions in the third argument. - breaking
canvassources now require acontextTypeoption specifying the drawing context associated with the source canvas. #5155
:sparkles: Features and improvements
Correct rendering for multiple
fill-extrusionlayers on the same map #5101Add an
icon-anchorproperty to symbol layers #5183Add a per-map
transformRequestoption, allowing users to provide a callback that transforms resource request URLs #5021Add data-driven styling support for
Add support for SDF icons in
Map#addImage()#5181Added nautical miles unit to ScaleControl #5238 (h/t @fmairesse)
Eliminate the map-wide limit on the number of glyphs and sprites that may be used in a style #141. (Fixed by #5190, see also mapbox-gl-native#9213
Numerous performance optimizations (including #5108 h/t @pirxpilot)
:bug: Bug fixes
Add missing documentation for mouseenter, mouseover, mouseleave events #4772
Add missing documentation for
Marker#getElement()method #5242Fix bug wherein removing canvas source with animate=true leaves map in render loop #5097
Fix fullscreen detection on Firefox #5272
Fix z-fighting on overlapping fills within the same layer #3320
Fix handling of fractional values for
layer.minzoom#2929Clarify coordinate ordering in documentation for
centeroption #5042 (h/t @karthikb351)Fix output of stop functions where two stops have the same input value #5020 (h/t @edpop )
Fix bug wherein using
Map#addLayer()with an inline source would mutate its input #4040Fix GPU-specific bug wherein canvas sources caused an error #4262
Fix a race condition in symbol layer handling that caused sporadic uncaught errors #5185
Fix bug causing line labels to render incorrectly on overzoomed tiles #5120
Fix bug wherein
NavigationControltriggered mouse events unexpectedly #5148Fix bug wherein clicking on the
NavigationControlcompass caused an error in IE 11 #4784Remove dependency on GPL-3-licensed
fast-stable-stringifymodule #5152Fix bug wherein layer-specific an event listener produced an error after its target layer was removed from the map #5145
Fix
Marker#togglePopup()failing to return the marker instance #5116Fix bug wherein a marker's position failed to adapt to the marker element's size changing #5133
Fix rendering bug affecting Broadcom GPUs #5073