unstale

npm / lightweight-charts

lightweight-charts

What changed in lightweight-charts 5, from its official release notes, upgrade guides and advisories. Sources checked 2026-11-30.

4 breaking12 new APIs and options3 performance2 behavior and defaults2 tooling23 fixes and other

See which of these apply to your code, ranked, in your agent:

npx @unstale/cli init

@unstale/cli on npm

lightweight-charts 546 changes

Breaking changes 4

  • Business day strings must use zero-padded YYYY-MM-DD format in all builds; other formats throw, so use that format or a BusinessDay object.

    5.3.0release notes

  • The pane separator colour is applied as background-color rather than the background shorthand, so only colour values are accepted.

    5.3.0release notes

  • Curved lines use Fritsch-Carlson monotone interpolation instead of Catmull-Rom, avoiding overshoot; curves may look different.

    5.3.0release notes

  • Markers larger than size 1 are no longer re-clamped to 30px in the renderer, so shapes scale with size and arrow tips remain aligned with the anchor price.

    5.2.1release notes

New APIs and options 12

  • Adds a per-price-line hit tolerance in pixels; the default remains 7, matching previous behavior.

    5.3.0release notes

  • Adds a chart option to choose which visible price scale is preferred by default when both left and right scales are available; defaults to right.

    5.2.0release notes

  • Adds hovered-series and associated object metadata to mouse event payloads.

    5.2.0release notes

  • Adds an option, defaulting to true, that renders the currently hovered series above other series in the same pane.

    5.2.0release notes

  • Custom series can opt in to hit testing with an optional hook; a geometry-based fallback is used when it is not provided.

    5.2.0release notes

  • Adds control over price-scale tick mark label density; higher values mean more spacing and fewer tick marks, and lower values mean less spacing and more tick marks. Defaults to 2.5.

    5.2.0release notes

  • Adjusts the zoom level threshold for conflation activation and can create smoothing effects.

    5.1.0release notes

  • When enabled, the crosshair snaps to the nearest visible series data point instead of snapping to hidden series indices.

    5.1.0release notes

  • Plugin developers can implement custom aggregation logic through this interface.

    5.1.0release notes

  • Enables or disables data conflation; it is disabled by default.

    5.1.0release notes

  • Pre-calculates conflated data on initialization to improve zoom performance, at the cost of initial load time and memory usage; defaults to false.

    5.1.0release notes

  • Controls background computation priority when using the Prioritized Task Scheduling API; defaults to 'background'.

    5.1.0release notes

Performance 3

  • Whitespace generated by a yield curve chart's minimumTimeRange is capped at 100,000 points to prevent very large values from freezing the page while allocating memory.

    5.3.0release notes

  • Improves performance on charts combining series markers with large datasets by avoiding cloning the entire series dataset on every mouse move.

    5.2.1release notes

  • When enabled, conflation merges data points when zoomed out to improve rendering performance for large datasets.

    5.1.0release notes

Behavior and default changes 2

  • Requesting options for an overlay price scale without series now returns the options it will be created with, based on the chart's overlayPriceScales option.

    5.3.0release notes

  • When enabled, hovering an Area or Baseline series renders its stroke, point markers, and price lines on a top layer while the fill stays at its natural z-order.

    5.2.1release notes

Tooling 2

  • Adds an Agent Skill that teaches AI coding assistants Lightweight Charts v5 API conventions, mental models, and common foot-guns.

    5.2.1release notes

  • Each push to master publishes a compact preview package, making unreleased changes easier to test.

    5.2.0release notes

Fixes and other changes 23

  • Custom localization formatters are now removed when set back to undefined via applyOptions.

    5.3.0release notes

  • Area and Baseline series no longer throw on redraw for unparseable fill colours; such colours are drawn as transparent.

    5.3.0release notes

  • createChart no longer throws when its options object has its own hasOwnProperty key.

    5.3.0release notes

  • Prices are rounded rather than truncated when minMove is 1 or greater.

    5.3.0release notes

  • Series with equal visible values around 1e15 and above are drawn instead of having an empty range.

    5.3.0release notes

  • Avoids a crash in environments where navigator.userAgentData.brands is undefined, including some WebView and privacy-restricted browsers.

    5.3.0release notes

  • Pane, separator, and time-axis sizing no longer exceeds chart height at fractional device pixel ratios, preventing a one-pixel time-axis shift when panes change.

    5.3.0release notes

  • The precision option is now honored for the percent price format, including precision 0.

    5.3.0release notes

  • The option now uses scheduler.postTask in production, so precomputeConflationPriority has an effect.

    5.3.0release notes

  • Animated scrolling now reaches its target, including when the first animation frame arrives after the duration; kinetic scrolling no longer skips its final frame.

    5.3.0release notes

  • Historical updates at times without a bar insert the new bar there instead of overwriting the next bar; whitespace updates no longer remove the next bar.

    5.3.0release notes

  • Calling setData with identical times and then adding another series no longer makes the chart empty or causes getVisibleLogicalRange to return null.

    5.3.0release notes

  • Setting a visible range no longer collapses the requested range when zoomed in below the minimum visible bars count.

    5.3.0release notes

  • Adding new bars while the user drags the chart no longer makes the time scale jump.

    5.3.0release notes

  • Default tick mark labels during the hour skipped when daylight saving time starts no longer display an hour late or disagree with crosshair labels.

    5.3.0release notes

  • Resets the provider when explicitly set back to undefined via applyOptions, restoring autoscaling after a custom provider was used.

    5.2.1release notes

  • Prevents a Value is null error when replacing multiple series with shorter datasets while the crosshair hovers over data by invalidating affected pane views before time scale changes.

    5.2.1release notes

  • Fixes visual jitter when auto-sized charts are resized within dynamic containers; ResizeObserver-triggered resize behavior now paints synchronously.

    5.2.0release notes

  • Dash phase remains continuous when a series changes stroke color per data item, preventing dash patterns from restarting at color boundaries.

    5.2.0release notes

  • Fixes point markers not being drawn correctly when per-point colors change.

    5.2.0release notes

  • Fixes a visual bug where a pane's DOM element could remain on screen after removing its last series when that series contained large values.

    5.2.0release notes

  • The time scale method now respects the rightOffset option when rightOffsetPixels is not set.

    5.1.0release notes

  • Price axis label positioning no longer treats plugin views without this optional method as positioned at coordinate 0, avoiding false overlap detection.

    5.1.0release notes