0👍
As reported in the comment, you scales
config is not correct.
I have changed it (there were other misconfigs) and the following config should be correct:
scales: {
x: {
type: 'time',
time: {
displayFormats: {hour: 'HH:mm'},
},
grid: {
color: 'black'
},
ticks: {
font: {size: 40},
color: 'black',
},
},
y: {
type: 'linear',
grid: {
color: 'black'
},
position: 'left',
ticks: {
color: 'black',
max: 1,
min: 0
},
title: {
display: true,
color: 'black',
text: 'Leistung (WATT)'
},
},
},
- Chartjs-How can I add a label above just the last bar in a Chart.JS bar chart?
- Chartjs-How to order tooltip values from the biggest to the smallest
Source:stackexchange.com