unstale

npm / lightweight-charts

lightweight-charts

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

1 breaking12 new APIs and options2 performance1 behavior and defaults2 tooling8 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 526 changes

Breaking changes 1

  • 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 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

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

    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 2

  • 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 1

  • 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 8

  • 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