Error: chart[chartType] is not a function at char.js 2.0
Hello, thank you very much to for sharing this directive, it's very useful. However I have the following issue:
I have included charts.js v2.0 and then the directive and I get this error
Error: chart[chartType] is not a function
Any idea why the function Chart.Line() (or whatever) is not defined?
Also getting this problem.
Same problem.
Chart 2.1.3 is giving me same problem
No fix yet?
Hi! This directive only work for chartjs v1, i.e, Chart.Line(), Chart.Bar() and etc is supported. In second version of chartjs is different:
var ctx = document.getElementById('chartId').getContext('2d');
var chart = new Chart(ctx, optionsObj);
It's recomended if you dont want use version 1, update this directive using the new way. In version one, you determine what chart type. In new version, you pass in options object the type of chart.
To get more information, read the chatjs docs: http://www.chartjs.org/docs/#chart-configuration-creating-a-chart-with-options.
Regards!
why don't you update your module ? instead of everyone updating for himself ?
or shall we make a fork of this ? software products has to keep updating...
Same problem
I found solution by using CDN for Chart.js
instead chart.js v2