react-chartjs-2 icon indicating copy to clipboard operation
react-chartjs-2 copied to clipboard

Bar chart renders half of the data only

Open jacky-ew opened this issue 5 years ago • 2 comments

The bar chart renders only half the data. renders only even number indexed. (0, 2, 4, 6). Is this a bug ? Any advice to the problem

jacky-ew avatar Apr 30 '20 01:04 jacky-ew

Can you post an example of the data being passed in so this issue can be recreated?

jhonnold avatar Apr 30 '20 12:04 jhonnold

I had the same issue but I managed to fix it with this option: options={{ maintainAspectRatio: false }}

e.g. <Line data={this.state} options={{ maintainAspectRatio: false }} />;

amir04lm26 avatar May 19 '20 18:05 amir04lm26