reactjs / react-chartjs

common react charting components using chart.js
MIT License
2.93k stars 301 forks source link

v2: support horizontalBar chart #115

Open ghost opened 8 years ago

ghost commented 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

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?

OddEssay commented 8 years ago

I put a PR #122 that addresses this.

ghost commented 8 years ago

@OddEssay Great work 👍

ramimazid commented 7 years ago

@OddEssay How do you get HorizontalBar to work in your branch? It returns undefined when I reference it.