reactjs / react-chartjs

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

Uncaught TypeError: chart is undefined (Firefox) / Cannot read property 'name' of undefined (Chrome) #74

Closed theo07 closed 8 years ago

theo07 commented 8 years ago

I am generating a number of charts by listening to an event. Every event fired will generate or remove one chart.

Everything works fine but I see this Uncaught TypeError in the console: chart is undefined (Firefox) / Cannot read property 'name' of undefined (Chrome).

module.exports.createClass.classData.componentWillReceiveProps

If I add a null check in the library the type error seems to disappear. But I have to say that there is the possibility of using the library wrong.

Any suggestions/fixes would be greatly appreciated.

Many thanks, Teo

austinpray commented 8 years ago

Can you post the code that you changed to mitigate this error? Odds are this needs to be a PR.