chartjs y axis start from 0 if all values is zeros

Viewed 17

i am using react-chartjs-2 v4.1.0 and chart.js v3.9.1

and i have this issue here

line chart image

how to force chartjs to start from 0 on y-axis?

(some additional info here)

my line chart options: enter image description here

1 Answers

You need to set min: 0 in the root of the y axis options object instead of it being nested inside of the ticks options

Related