Professional-grade charting
Candlesticks, bars, line and area — switchable in place. Smooth pan/zoom, crosshair, volume sub-pane and a current-price line out of the box.
A dependency-free charting library with professional-grade candlesticks, indicators, drawing tools and live data — while staying small and easy to wire to any source.
npm i @lightfin/core
A real @lightfin/core chart with its full chrome,
streaming live BTC/USDT from Binance.
Candlesticks, bars, line and area — switchable in place. Smooth pan/zoom, crosshair, volume sub-pane and a current-price line out of the box.
SMA, EMA, Bollinger, RSI, MACD, ATR, Stochastic and Volume MA, each on its own resizable pane via a tree-shakeable indicator framework.
Trend lines, channels, pitchfork, regression, Fibs, shapes, brush, labels, and position/range measures — with undo/redo and a per-drawing style toolbar.
Bars in, chart out. Attach a DataSource for history backfill and a live stream; follow-mode keeps the latest candle in view.
A thin <LightfinChart> wrapper plus a useChartEffect hook wire features imperatively onto the chart while the core stays framework-free.
Not one transitive package — no supply-chain surface to audit, no CVEs to chase. The whole library is yours to review, which risk and compliance teams tend to ask about.
Our chart lazily loads optional features like toolbars, annotations and indicators, so you only pay for what you use.
Lightfin sizes are brotli-compressed and enforced in CI. The comparison bar is capped — a 2 MB bundle is roughly 47× the full Lightfin build.
Optimized draw calls, carefully structured columnar data to minimise GC, and buttery gestures — right up to half a million candles.
Each series and indicator collapses to a handful of Path2D fills and strokes per frame — up/down candles bucketed by color, a whole line plot in one stroke.
Bars live in parallel typed-array columns — a gap-buffered store, not an array of objects — so appends, backfill and redraws barely touch the garbage collector.
A single requestAnimationFrame-batched scheduler coalesces every invalidation into one render pass, drawn on layered canvases at device-pixel sharpness.
O(1) viewport slicing keeps pan, zoom and live follow-mode fluid whether you are showing 500 candles or 500,000.
The core knows nothing about your data or framework. Create a chart,
add a series, hand it bars. Reach for @lightfin/react,
indicators, drawing tools or a live DataSource only when
you need them.
import { createChart } from '@lightfin/core'
const chart = createChart(document.querySelector('#chart'), {
volumeVisible: true,
})
chart.addCandlestickSeries().setData(bars)