Is your feature request related to a problem? Please describe.
Some implementations might desire the ability to only add series to the chart when data exists. For example, in the snippet below, if data is an empty array a blank chart will be rendered. Instead of rendering a blank chart we should render the no data ui.
{data.map((d) => (
<BarSeries
id="bars"
name="amount"
xScaleType={ScaleType.Ordinal}
xAccessor="x"
yAccessors={["y"]}
data={d}
/>
))}
Note: the empty chart only occurs when there is an Axis specified.
See https://codesandbox.io/s/wonderful-cannon-2yf9e?file=/src/App.tsx
Describe the solution you'd like
Show no data ui when there is are no series listed in the chart
Describe alternatives you've considered
Pass empty data to one of the series.
Is your feature request related to a problem? Please describe.
Some implementations might desire the ability to only add series to the chart when data exists. For example, in the snippet below, if
datais an empty array a blank chart will be rendered. Instead of rendering a blank chart we should render the no data ui.See https://codesandbox.io/s/wonderful-cannon-2yf9e?file=/src/App.tsx
Describe the solution you'd like
Show no data ui when there is are no series listed in the chart
Describe alternatives you've considered
Pass empty data to one of the series.