npm / ol
ol
What changed in ol 6 to 10, from its official release notes, upgrade guides and advisories. Sources checked 2026-11-30.
97 breaking4 deprecations76 new APIs and options8 performance41 behavior and defaults62 fixes and other
See which of these apply to your code, ranked, in your agent:
npx @unstale/cli initol 10129 changes
Breaking changes 9
Geometries with empty coordinate arrays, except GeometryCollection, are now parsed as null geometries to match the GeoJSON spec recommendation.
Color interpolation now uses sRGB on both Canvas and WebGL, so Canvas gradients may look different; interpolated channels retain fractional values.
WMTS tile grid extent now comes only from an advertised BoundingBox; getExtent() returns null when none is advertised, while tile requests use matrix sizes and limits.
WMTS capabilities-derived wrapX is now based on whether the first tile matrix spans the projection extent; override it to false if a single world copy is desired.
TextPath relies on Intl.Segmenter; very old browsers may need a polyfill.
The separate group option for the GeoZarr source was removed.
In Canvas flat styles, additional arguments to the get expression access nested properties or array items, so type hints are no longer needed.
The method moved from ol/source/VectorTile to ol/layer/VectorTile; update calls from the layer's source to the layer itself.
The opaque option was removed from all Tile sources because the renderer no longer needs this hint for optimizations.
Deprecations 4
The BingMaps source is deprecated; use ol/source/ImageTile with the Azure Maps tile API instead.
BingMaps for Enterprise is being retired on June 30th, 2028; the release recommends ImageTile with the Azure Maps tile API.
The ol/format/Polyline function is deprecated without replacement.
ol/array stableSort is deprecated; use the stable built-in Array.sort instead.
New APIs and options 32
Adds a fetchSessionToken option to Google.
The GeoZarr source can visualize generic n-D datacubes.
The method accepts a wrapX option.
Use interpolate-hcl to retain perceptual color gradients; it is currently supported only by the Canvas renderer.
Raster sources now have basic data tile support.
GeoZarr sources accept storeOptions for headers and credentials.
The new rotateContent option supports crisp rendering on rotated views, including rotated text and point symbols.
The WKT format accepts projection options.
The GeoZarr source supports selecting non-spatial dimensions, such as for time series.
GeoZarr adds support for proj:projjson and proj:wkt2.
Sentinelhub supports setting the response format.
WebGL vector renderers now support text.
GeoTIFF sources now support a custom fetch client.
The ImageLayer base now includes the background option.
GeoTIFF source options now support attributions.
An experimental source supports raster data conforming to the evolving GeoZarr specification.
Modify options now accept a filter function.
A new source supports OGC API Maps.
The new stroke offset option enables line offsets in Canvas rendering.
Canvas map targets support pixelRatio, and the map now has pixelRatio getter and setter methods.
Property definitions now support generics, enabling typed property definitions.
Support for ReferrerPolicy when fetching source data and icons lets requests include a referer header where required.
Bing Maps and Google sources gain extra URL options.
The Extent interaction gains createCondition and drag options.
Icon style gains a setSrc method for changing its source.
Draw gains a setter and getter for freehand.
ol can be used inside a worker, with full Map support and an (Offscreen)Canvas as the map target.
ZoomToExtent gains FitOptions.
Select gains methods for adding and removing features.
WebGL styles gain the stroke-pattern-start-offset style property.
URL templates using {z}/{x}/{y} are supported.
A new image tile source provides a base source for image tile sources, with improved performance and simplified code.
Performance 8
Tiles no longer needed by the current view are dropped from the queue.
The WebGL text overlay worker is loaded on demand.
Tile rendering draws only lower-zoom remainders instead of clipping and redrawing full tiles.
Opened arrays are cached across tile loads, band arrays open in parallel, tile sizes align with inner shards, and concurrent byte-range requests are coalesced.
Loading striped GeoTIFFs and reprojected WebGL tiles is more efficient.
Filtering out features in WebGL rendering is more efficient.
WebGL instanced rendering improves performance and memory usage.
WebGL layers use a single buffer to improve memory usage.
Behavior and default changes 22
Canvas styles now evaluate the array operator.
WFS 2.0.0 transaction filters now use fes:ResourceId.
APIs that required a Promise now accept any thenable.
When matrixLimits is passed, the returned tile grid restricts requests to the advertised row and column bounds for each zoom level.
The GeoJSON reader uses the configured featureClass to instantiate a Feature.
Images in multi-page GeoTIFFs are sorted automatically.
Long lines are clipped at the render extent boundary for text rendering.
VectorSource removes loaded extents by overlap rather than exact match.
Style variable values are used to determine the type of an expression.
GeoTIFF sources provide min, max, and nodata values per band.
GeoTIFF sources can load unknown projections.
GeoZarr sources can load bands from multiple Zarr groups.
Hit detection now has a default stroke.
The flat-style in operator now accepts literal number arrays as its haystack.
Shared vertices are treated as equal.
Resolution is computed from spatial:bbox and spatial:shape.
Vector tile layers are clipped at the layer extent.
Generic projection code lookup is based on spatialreference.org.
Tracing is supported with the Modify interaction.
VectorTile layers now support reprojection.
Generic types were improved and made more consistent for vector and vector tile layers, sources, and formats.
The get expression supports accessing nested properties.
Fixes and other changes 54
Canvas styles now evaluate the color operator.
The function now respects the stride parameter.
Fixes target cleanup for MouseWheelZoom.
Fixes rendering of RTL text along lines.
Text is aligned to the visible part of a line only when textAlign is undefined.
Nested WFS 2.0 FeatureCollections are now read correctly.
ImageArcGISRest and TileArcGISRest now support ArcREST case sensitivity.
Decluttering z-index ordering has been fixed.
WebGLTile layers now use the correct GeoTIFF alpha band.
setParams resets the loader for image sources.
Text is split by graphemes so ligatures are no longer cut apart.
LinearRing extent intersection handling has been fixed.
Tracing in the Modify interaction has been fixed.
Text placed along a line now honors offsetX.
Transparency outside source coverage is handled on reprojected WebGLTile layers.
Transforms are no longer skipped on rotated maps.
hasFeature uses an identity check when a feature has an id.
Incorrect VectorTile source resolution calculation has been fixed.
WebGL tile rendering now handles stale tiles.
Cloning a Feature with a custom geometry name is fixed.
GeoZarr nodata handling was improved.
Blur and radius expressions now work after inlining blurSlope computation.
A stroked polygon renders correctly after a non-stroked polygon when overlaps is false.
Snap intersections with mixed GeometryCollection geometries are fixed.
Text on circle features now works with decluttering.
Trackpad pinch-to-zoom deltas are inflated, and zoom feel is consistent with and without constrainResolution.
Failure handling for promise-based vector loaders was fixed.
Hit detection now works for features beyond tile boundaries.
Rendering precision was improved to eliminate artifacts when zoomed in.
Artifacts when zooming far into a WebGLTile layer were fixed.
Geometry updates preserve per-geometry Z and M values.
Dynamic icon color handling for Canvas was fixed.
The bandCount property now works for band expressions.
The Heatmap class now includes its missing event types.
Hit detection at polygon edges was fixed.
setParams() now updates the image request parameters.
The link interaction now works with views that are not fully defined.
The first and last vertices of a polygon are synchronized during a modify drag.
Pattern fill rotation was fixed.
Blank input tiles are avoided when reprojecting.
Feature collection events now fire in the correct order.
Vector layer wrapping behavior was fixed.
The tile cache for raster reprojection source tiles is restored.
Glitched rendering in ReprojDataTile is fixed.
Snap receives fixes, including avoiding duplicate snap events registered on the same feature.
Duplicate rendering is prevented for vector tiles using renderMode: 'vector'.
Boolean attributes in WebGL expressions are now handled properly.
The bounding box from the layer is used in WMTS capabilities.
Area calculation precision was improved by using an offset from the start instead of the full coordinate.
Passing an apiOptions array to the Google source was fixed.
Non-string text styles work again.
OverviewMap behavior was fixed for setView() and useGeographic().
OverviewMap behavior was fixed when useGeographic() is used.
Existing buffers are cleared before new ones are allocated, fixing a memory allocation issue.
ol 920 changes
Breaking changes 6
Decluttered items in Vector and VectorTile layers keep layer and within-layer render order instead of being lifted above the layer stack.
The method returns the drawn feature or null when drawing could not be finished, rather than undefined.
This method was removed; callers can remove it because decluttering no longer lifts elements above the layer stack.
The constructor now requires a Geometry array; an empty array remains valid.
The shape-radius1 property was removed; use shape-radius instead.
The radius1 property was removed; use radius for regular polygons or radius and radius2 for stars.
New APIs and options 5
Flat styles in the Canvas renderer gained fill pattern support and case expressions.
The coalesce operator was added to expressions.
A Google Maps source is available for using Google Maps as a source in OpenLayers.
GPX metadata parsing was added.
Vector and VectorTile source format types are now generic.
Behavior and default changes 8
Drawing ends when appendCoordinates() reaches maxPoints.
The source accepts any service URL.
RGBA strings created from color arrays use increased alpha precision.
The return types are more specific.
The return type is now this.
The return type was improved.
Flat styles in the WebGL renderer gained broader support, including an extended color operator and the geometry-type operator in CPU rendering.
WebGL line rendering gained improved antialiasing.
Fixes and other changes 1
Empty coordinate arrays work again when reading GeoJSON.
ol 824 changes
Breaking changes 14
Immediate renderer drawFeature no longer resets an application-set canvas context transform; applications relying on the previous behavior must reset the context themselves.
Immediate renderer drawGeometry no longer resets an application-set canvas context transform; applications relying on the previous behavior must reset the context themselves.
The icon-img-size flat style property is no longer needed and has been removed.
The imgSize property is no longer needed and has been removed.
The imageSize pseudo option has been removed; remove it if used to provide the actual image size, or calculate the imageExtent if reproducing its unintended behavior.
Deprecated ol/AssertionError and its error codes have been removed.
The MapboxVector layer was removed; use MapboxVectorLayer from ol-mapbox-style version 11 or greater instead.
The Buffer class has been removed from the API.
The PostProcessingPass class has been removed from the API.
The RenderTarget class has been removed from the API.
Use the StadiaMaps source instead of the Stamen source; the former Stamen layer names use the stamen_ prefix.
When a Stroke with lineDash is passed to RegularShape or Circle, the default lineCap is now round instead of the canvas default butt.
WebGL helper classes were removed from the API.
WebGLPointsLayer now supports only the flat style format; the previous custom symbol format no longer renders. The same change applies to WebGLVectorLayerRenderer and WebGLVectorTileRenderer.
New APIs and options 3
Expression-based styling was added.
A projection can now be set for GeoTIFF data.
Image sources gained a loader-based API using ImageBitmap, making work with non-tiled raster data more modular and faster.
Behavior and default changes 3
The BingMaps source no longer requires placeholderTiles to be set.
WebGL symbol rendering was reworked to include circles with outlines, shapes, and icons.
WebGL vector layers support the XYM geometry layout.
Fixes and other changes 4
Keeping the declutter tree improves hit detection.
The return type of Layer#renderFrame was corrected.
lineCap was retained for styling closed paths after its removal was reverted.
The OGCVectorTile source types were fixed.
ol 718 changes
Breaking changes 14
Icon and RegularShape displacement is no longer scaled with the image; increase displacement when setting scale if relying on the previous behavior.
This deprecated method has been removed from Map.
The Helper constructor from ol/webgl/Helper.js is no longer part of the public API.
The imageSmoothing option has been removed from sources.
Internet Explorer is no longer supported.
Graticule default intervals now align better with integer minutes and seconds; decimal-degree formatting may need custom intervals.
The labelCache has been removed from the ol/render/canvas.js module.
Deprecated options have been removed from the Overlay component.
MousePosition now keeps displaying the last mouse position when the pointer leaves the viewport by default; placeholder no longer accepts false.
PluggableMap has been removed; custom map classes should extend Map instead.
Inserting beyond the current Collection length now throws an error instead of creating a sparse Collection; this also applies to insertAt.
The tilePixelRatio property has been removed from the DataTile source.
Longitude and latitude formatting omits minutes and seconds when they are zero, changing values displayed on graticules.
The MousePosition control option has been removed; use placeholder instead.
New APIs and options 3
The link interaction is now re-exported from the interactions module.
Static layer styling now accepts an object literal.
Experimental low-level WebGL vector rendering now supports lines and polygons in addition to points.
Behavior and default changes 1
Drag and Drop now supports user projections.
ol 697 changes
Breaking changes 54
This replaces the view rotate method and takes a rotation delta as input.
AtlasManager was removed because it was only used by the experimental WebGL renderer.
The behavior of clear() and refresh() on sources is clarified and changed.
The option is no longer supported by View.fit, PinchZoom, MouseWheelZoom, or ol/interaction.js; it is supported only by View.
CSV parsing skips the header and bad data.
Decluttering is coordinated across Vector and VectorTile layers, prioritizes higher-z-index layers, and reverses within-layer zIndex priority; VectorImage layers remain separate.
The EsriJSON format no longer mutates its input.
The optional this argument was removed; use a closure, arrow function, or bind instead.
The non-API style getChecksum functions were removed.
This renamed method replaces getGetFeatureInfoUrl on ImageWMS and TileWMS.
The method now returns an empty array rather than null when no features are found.
The method on ImageWMS and TileWMS was renamed to getFeatureInfoUrl.
getPointResolution returns resolution in projection units.
The deprecated getSnapToPixel and setSnapToPixel functions are removed.
Explicitly creates a vector context for immediate rendering from a render event; importing it makes the immediate rendering API an explicit dependency.
Unfilled Circle geometries and Circle or RegularShape styles no longer detect hits in their interiors; specify a transparent Fill for the previous behavior.
The deprecated getSnapToPixel and setSnapToPixel functions were removed.
The prototype inheritance helper was removed; use standard ECMAScript classes instead.
A layer can now belong to only one map.
This PluggableMap option is no longer supported because the new DOM composition strategy does not need to postpone tile loading.
The optional this argument was removed; use a closure, arrow function, or bind instead.
Canvas reuse can cause this method to report false positives; assigning distinct layer className values avoids them but can significantly reduce performance.
Views now restrict display to one world and prevent panning beyond the north or south edge; set multiWorld: true for the previous behavior.
getLastExtent was removed because it is no longer needed for custom vector-source tileLoadFunction implementations.
The MVT format uses the PBF type instead of Object.
The graticule API was replaced by the ol/layer/Graticule layer.
CANVAS_LINE_DASH is removed from ol/has.
The GEOLOCATION constant was removed; check whether 'geolocation' is defined in navigator instead.
The TOUCH constant was removed; check whether 'ontouchstart' is defined in window instead.
Graticules are now layers that can be added to a map.
Call this to re-render a vector layer instead of using source refresh for that purpose.
Use this layer with ol/source/Vector in place of Vector layers configured with renderMode: 'image'.
clear no longer reloads data from the server; use refresh to refetch.
refresh now removes all features and triggers a server reload; use Vector#changed to re-render without refreshing data.
These methods were removed; custom VectorTile source tileLoadFunction implementations now pass extent and projection to readFeatures instead.
These methods now apply view constraints instead of bypassing them, so the actual view state can differ from the target values.
CSS media print rules were removed; add a print rule to hide .ol-control to retain the previous behavior.
The control must be constructed with a list of layers because layers can only belong to one map.
This layer event replaces postcompose and the previous render event.
Register for the layer prerender event instead.
This layer event replaces precompose for rendering-related event handling.
The optional this argument was removed; use a closure, arrow function, or bind instead.
Use the layer postrender event instead.
The glContext property was removed from RenderEvent.
The setDeclutter function was removed.
Internal tile rows now increase downward like standard XYZ coordinates; custom tileLoadFunction and tileUrlFunction implementations may need to stop negating y.
The tilePixelRatio options were removed from ol.source.VectorTile.
The image renderMode option was removed for Vector layers; use VectorImage with an ol/source/Vector instead.
Vector sources prevent adding features with duplicate ids to the collection.
The vector render mode was removed; hybrid and image remain available.
The loader receives extent and projection; pass them as extent and featureProjection options to the format's readFeatures method rather than setting tile projection and extent.
The method is gone and has been replaced by adjustRotation, which accepts a delta.
A function now provides lightweight, low-level access to the WebGL API.
The experimental WebGL map renderer was dropped; WebGLHelper provides low-level WebGL access instead.
New APIs and options 33
Circle geometry implements rotate and translate functions.
Collection events include an index.
This view option retains the previous behavior of constraining only the view center.
All geometries implement containsXY.
DragPan gains a primaryAction condition.
DragZoom gains a minArea constructor property.
GeometryCollection is re-exported from ol/geom.
Adds an IIIF Image API tile source and finalizes support for Image API version 3.
Image layers gain prerender and postrender events.
The Layer class supports a custom render function.
Maps can compose layers using different renderer technologies, including custom renderers.
Layers can be configured with zoom limits.
MouseWheelZoom gains a maxDelta constructor property.
Base layers gain a className property.
TileJSON sources accept a tileSize option, allowing developers to configure tile dimensions.
RasterSource supports attributions.
The scaleline control gains a scalebar option.
Text styles gain setRotateWithView to control whether text rotates with the view.
Feature formats support tile pixel projections.
Users can opt out of tracking.
The translate interaction accepts a filter function.
An experimental function is available; it is not yet part of the stable API.
VectorImage layers gain an imageRatio option.
Vector tile sources gain an attributionsCollapsible option.
Vector tile layers can now use declutter: true with renderMode: 'image'; decluttering is per tile and may cut off labels or symbols at tile boundaries.
View constraints were refactored and a view extent constraint was added.
A setter was added for the View class's constrainResolution setting.
The WebGL points renderer supports hit detection.
The WebGL points renderer gains texture and color support.
A new layer provides simple rendering of large numbers of points with custom shaders and is used by Heatmap.
Tile sources and Zoomify support a configurable zDirection option.
Zoomify accepts a zDirection option.
Zoomify supports TilePixelRatio.
Behavior and default changes 7
The onBoxEnd property in DragBox options is optional.
An arbitrary tag can be used as a feature id.
Hand-created WMTS tile grids with top-left origins no longer require negative heights in sizes; bottom-origin custom sizes must use negative heights.
Vector layers using renderMode: 'image' can use decluttering.
The projection property in source options is optional.
The urls property in source options is optional.
The view center is no longer rounded to pixels.
Fixes and other changes 3
Hit detection avoids false positives for lines and polygons and works for WebGL layers on retina devices.
Modify.removePoint returns true only when a vertex was removed.
An upgrade note calls out renderMode: 'image' for vector layers.