Recharts Skip a Bar

2019-07-28 07:55发布

问题:

I have some data that looks like this:

[{ a: 15, b: 30, c: 25, d: 12 }, { a: 15, c: 25, d: 12 }]

I want to render a barchart that skips the space in between a and c if b is undefined, but will still render b if it is defined.

Basically like the two bar chart groups in this image where the orange bar is skipped because there is no data for it

标签: recharts