Open ghost opened 8 years ago
Chart.js supports horizontalBar charts as of lately, see: http://jsfiddle.net/3xts05xu/
But it's impossible to pass horizontalBar type, because type gets lowercased on this line: https://github.com/jhudson8/react-chartjs/blob/chartjs-v2/lib/core.js#L76
horizontalBar
What is the purpose behind .lowercase()? Wouldn't it be better to allow to pass any type and leave it up to chart js to throw error?
.lowercase()
I put a PR #122 that addresses this.
@OddEssay Great work 👍
@OddEssay How do you get HorizontalBar to work in your branch? It returns undefined when I reference it.
HorizontalBar
undefined
Chart.js supports horizontalBar charts as of lately, see: http://jsfiddle.net/3xts05xu/
But it's impossible to pass
horizontalBar
type, because type gets lowercased on this line: https://github.com/jhudson8/react-chartjs/blob/chartjs-v2/lib/core.js#L76What is the purpose behind
.lowercase()
? Wouldn't it be better to allow to pass any type and leave it up to chart js to throw error?