Packages

mapbox-gl

3.34.2 · 3 Nov 2026SEE LICENSE IN LICENSE.txt6M / weekRepositoryHomepagenpmAtom feed

Your version

0.48.0

17 Aug 2018Where it was published

0.54.1 is the newest release of 0.48.x.

In short

1 breaking7 new4 faster9 fixed

  • breaking

    Treat tiles that error with status 404 as empty renderable tiles to prevent rendering duplicate features in some sparse tilesets

Release note

Breaking changes

  • breaking

    Treat tiles that error with status 404 as empty renderable tiles to prevent rendering duplicate features in some sparse tilesets

Bug fixes

  • Fix issue where text-max-angle property was being calculated incorectly internally, causing potential rendering errors when "text-placement": line

  • Require feature.id when using Map#setFeatureState

  • Fix issue with removing the GeolocateControl when user location is being used (#6977) (h/t sergei-zelinsky)

  • Fix memory leak caused by a failure to remove all controls added to the map

  • Fix bug where the build would fail when using mapbox-gl webpack 2 and UglifyJSPlugin (#4359, fixed by #6956)

  • Fix bug where fitBounds called with coordinates outside the bounds of Web Mercator resulted in uncaught error (#6906, fixed by #6918)

  • Fix bug wherein Map#querySourceFeatures was returning bad results on zooms > maxZoom

  • Relax typing for equality and order expressions (#6459, fixed by #6961)

  • Fix bug where queryPadding for all layers in a source was set by the first layer, causing incorrect querying on other layers and, in some cases, incorrect firing of events associated with individual layers

Features and improvements

  • Performance Improvements:

    • Stop unnecessary serialization of symbol source features.

    • Optimize calculation for getting visible tile coordinates

    • Improve performance of creating {Glyph/Image}Atlases

    • Optimize and simplify tile retention logic

  • Add a user turnstile event for users accessing Mapbox APIs

  • Add support for autogenerating feature ids for GeoJSON sources so they can be used more easily with the Map#setFeatureState API (#7043))

  • Add ability to style a symbol layer labels with multple fonts and text sizes via "format" expression

  • Add customAttribution option to AttributionControl (#7033) (h/t mklopets)

  • Publish Flow type definitions alongside compiled bundle

  • Introduce symbol cross fading when crossing integer zoom levels to prevent labels from disappearing before newly loaded tiles' labels can be rendered

  • Improvements in label collision detection (#6925))