Headless mode
Skip the EliteChart chrome — mount the engine directly with @elitechart/core or @elitechart/react.
If EliteChart's toolbar, sidebars, and modals are too much chrome
for your product, drop down to @elitechart/core or
@elitechart/react and mount only the canvas. Same data contracts,
same indicators, same drawings — your chrome.
Quick example — vanilla TS
Quick example — React
How it works
createChart(container, options) returns a ChartHandle. The handle
is the full programmatic API — setBars, setTheme, addIndicator,
addDrawing, subscribe, dispose. Nothing else mounts; you own
every wrapper element.
@elitechart/react is a thin convenience layer around the same
handle — a <Chart /> ref-mountable component plus useChart() and
useChartTheme() hooks.
Variations
Add an indicator headlessly
Tear down on unmount
API
| Symbol | From | Returns |
|---|---|---|
createChart(container, options) | @elitechart/core | ChartHandle |
<Chart ref options /> | @elitechart/react | React component |
useChart(ref) | @elitechart/react | ChartHandle | null |
useChartTheme(handle, initial) | @elitechart/react | [theme, setTheme] |