Componentcharts0.66 KB gzipZero dependencies

Candlestick Chart

OHLC candlestick chart for financial data visualization

Preview

Live Preview
Open ↗

Installation

Tokens guide →

Add to your project via CLI (zero dependencies, code you own):

npx bigbullui add candlestick-chart

Or install the full npm package:

npm install bigbullui

Usage

tsx3 lines
import { CandlestickChart } from "@/components/ui/candlestick-chart"; <CandlestickChart points={points} />

Source code

candlestick-chart.tsx + 1 helper

Zero third-party dependencies (2 local files shown in tabs below).

tsxcandlestick-chart.tsx100 lines
"use client"; import * as React from "react";import { cn } from "./lib/utils"; export interface CandlestickPoint {  open: number;  high: number;  low: number;  close: number;  label?: string;} export interface CandlestickChartProps extends React.HTMLAttributes<HTMLDivElement> {  points: CandlestickPoint[];  className?: string;} 

Props

PropTypeDescription
pointsCandlestickPoint[]Configures points. (Default: [])
classNamestringOptional Tailwind or custom CSS classes merged with component styles.