I have a 2D chart, by default the datalabels ar shown in the middle of the bar.
But I need them on top of the bar.
I tried in General “configuration”:
{
options: {
datalabels: {
anchor: 'end',
align: 'top'
}
}
}
but no success.
I have a 2D chart, by default the datalabels ar shown in the middle of the bar.
But I need them on top of the bar.
I tried in General “configuration”:
{
options: {
datalabels: {
anchor: 'end',
align: 'top'
}
}
}
but no success.
found a solution, strange is that rotation 360 is needed otherwise text is not correct rotated.
{
options: {
plugins: {
datalabels: {
anchor: 'end',
align: 'top',
rotation: 360,
color: 'blue',
font: {
weight: 'bold',
}
}
}
}
}
Using a Dashboard with multiple of these charts does not work anymore.
only for one chart it is working.
anyone got an idea?
Each chart has its own settings, make sure you set to each chart respectively.