ECharts: dataset with bars colored based on category name?

Viewed 371

I'd like to be able to control bar colors based on xAxis/category label name, throughout multiple charts, while using the dataset.source option of feeding data.

I'm guessing the solution might involve using visualMap?

customColors = {
 x1: '#123',
 x2: '#456',
 x3: '#789',
 ...
}

enter image description here

1 Answers
Related