MCPcopy Index your code
hub / github.com/reactchartjs/react-chartjs-2 / setOptions

Function setOptions

src/utils.ts:23–33  ·  view source on GitHub ↗
(chart: Chart<TType, TData, TLabel>, nextOptions: ChartOptions<TType>)

Source from the content-addressed store, hash-verified

21}
22
23export function setOptions<
24 TType extends ChartType = ChartType,
25 TData = DefaultDataPoint<TType>,
26 TLabel = unknown,
27>(chart: Chart<TType, TData, TLabel>, nextOptions: ChartOptions<TType>) {
28 const options = chart.options;
29
30 if (options && nextOptions) {
31 Object.assign(options, nextOptions);
32 }
33}
34
35export function setLabels<
36 TType extends ChartType = ChartType,

Callers 1

ChartComponentFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…