oki
oki

Reputation: 73

chart.js barchart without set fill color

This is my first time using Chart.js and I want to create bar chart with multiple series. Based on documentation we have to specify fillColor for each dataset. Is that possible to create multiple chart without set fillColor (like barchart in excel).

Upvotes: 6

Views: 15516

Answers (2)

User-8017771
User-8017771

Reputation: 1612

I know its very late, but we can achieve empty bar chart with only the border visible by setting the property : fill:false

Hope it helps someone :)

Upvotes: 3

w1n78
w1n78

Reputation: 789

fillColor uses rgba. a = alpha. you can set alpha value to 0. such as

fillColor: "rgba(220,220,220,0)"

this should give it a transparent fill color and still display the border colors assuming you have them not transparent.

Upvotes: 19

Related Questions