8000 GitHub - dominictobias/lightfin-chart: 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. · GitHub
[go: up one dir, main page]

Skip to content

About

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.

Resources

Stars

7 stars

Watchers

0 watching

Forks

Repository files navigation

Lightfin

npm @lightfin/core npm @lightfin/react

Monorepo for Lightfin, a lightweight, dependency-free financial charting library for the web — candlesticks, volume, indicators, drawing tools, smooth pan/zoom, and live data, rendered on HTML5 Canvas2D. The core is framework-agnostic vanilla TypeScript; framework bindings and the docs site live beside it.

Chart Screenshot

Library usage is in packages/core/README.md.

Packages

A Bun workspace. Packages live under packages/:

Package Name What it is
packages/core @lightfin/core The chart library. Zero runtime dependencies. Holds the demo/ playground and the Playwright e2e/ suite.
packages/react @lightfin/react React bindings (<LightfinChart> + hooks). react and the core are peer dependencies, so the core stays React-free.
packages/www @lightfin/www Marketing site and documentation (Astro + Starlight). Private; not published.

FAQ

Why did you use Canvas2D and not WebGL or WebGPU?

Measured in real browsers, Canvas2D was around 30% faster. Our batched Canvas2D raster work does not outweigh the cost of shader per-frame buffer upload and command submit.

Development

bun install
bun run dev        # serve the core /demo playground (app-mode Vite)
bun run www        # serve the docs site
bun run build      # build core and react (ESM + .d.ts) to packages/*/dist
bun run build:www  # build core, react, and the docs site
bun run test       # unit tests (Vitest) across packages
bun run test:e2e   # browser tests against the demo (Playwright)
bun run typecheck  # tsc --noEmit across packages
bun run size       # check built bundles against each package's .size-limit.json
bun run size:json  # rewrite packages/{core,react}/size.json for the landing page
bun run format     # prettier --write

Root scripts fan out to the workspace. Run one package with bun run --filter <name> <script> (for example bun run --filter @lightfin/react test). With bun run dev running, /stress.html loads 500k candles and benchmarks paint, calc, and backfill times.

License

MIT

About

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.

Resources

Stars

7 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages

0