MCPcopy Create free account
hub / github.com/ChartGPU/ChartGPU / getPointXY

Function getPointXY

src/renderers/createAreaRenderer.ts:40–45  ·  view source on GitHub ↗
(
  point: ResolvedAreaSeriesConfig['data'][number]
)

Source from the content-addressed store, hash-verified

38const isTupleDataPoint = (point: ResolvedAreaSeriesConfig['data'][number]): point is DataPointTuple => Array.isArray(point);
39
40const getPointXY = (
41 point: ResolvedAreaSeriesConfig['data'][number]
42): { readonly x: number; readonly y: number } => {
43 if (isTupleDataPoint(point)) return { x: point[0], y: point[1] };
44 return { x: point.x, y: point.y };
45};
46
47const computeDataBounds = (
48 data: ResolvedAreaSeriesConfig['data']

Callers 2

computeDataBoundsFunction · 0.70
createAreaVerticesFunction · 0.70

Calls 1

isTupleDataPointFunction · 0.70

Tested by

no test coverage detected