🚧 VeloxKit is pre-release software. APIs may change before v1.0. Get started →
Documentation
Packages
@velox/charts

@velox/charts

Line, area, bar, and pie/donut charts drawn on the GPU via the Canvas 2D path API (fill/stroke/arc). No DOM, no SVG. Charts redraw only when their props change, so they cost nothing while idle.

Install

npm install @velox/charts

Usage

import { LineChart, AreaChart, BarChart, PieChart } from '@velox/charts'
 
<LineChart data={[{ x: 'Jan', y: 12 }, { x: 'Feb', y: 19 }]} width={480} height={260} />
<AreaChart data={revenue} width={480} height={260} color="#4090F0" />
<BarChart  data={signups} width={480} height={260} />
<PieChart  data={[{ y: 30 }, { y: 50 }, { y: 20 }]} width={240} height={240} innerRadius={0.6} />

Each chart takes data (array of { x, y }, or { y, color? } for pie), width, height, plus optional color, showGrid, showLabels, showDots. Axis labels render with real glyphs via canvas fillText.