[Chartjs]-ChartJS 2.6 โ€“ Change color of bar in Bar chart programmatically

3๐Ÿ‘

โœ…

You should be able to access an array of the background colors directly in the datasets object:

chart.data.datasets[0].backgroundColor[0]

Example usage:
https://jsfiddle.net/6d0jsyxu/1/

Leave a comment