Skip to main content

Examples

Prediction Market — Yes/No Outcome

The probability price scale mode clamps the Y-axis to 0-100% with appropriate tick marks.

Multi-Outcome Event (e.g., Election)

OUTCOME_COLORS provides a 20-color palette optimized for dark backgrounds. Colors are auto-assigned by provider.event().

Candlestick + Volume

Instant Resolution Switching

After the first candles() call, trades are cached locally. Switching resolution rebuilds candles client-side with zero network calls:

Live Crypto with Short-Form Overlay

Interactive Crosshair

Orderbook with Depth Chart

Poll Multiple Outcomes

Responsive Chart

The chart auto-sizes to its container by default. Just give the container a CSS height:
For mobile, the chart handles touch events natively: single-finger drag to pan, pinch to zoom. No configuration needed.