问题
I want to use Chartjs(chartjs.org) as my charting tool along with AngularJS using TypeScript. I have installed DefinitelyTyped for Chartjs from GitHub to incorporate creation of Chartjs charts in my TypeScript written controller. I can't find any related questions on doing this thing.
I just need to know how we populate data to our charts using DefinitelyTyped.
回答1:
You can find example usages of chart.d.ts
in the form of a tests file right next to the definition : https://github.com/DefinitelyTyped/DefinitelyTyped/blob/master/types/chart.js/chart.js-tests.ts
来源:https://stackoverflow.com/questions/29885809/how-to-work-out-chartjs-using-typescript-with-chartjs-definitelytyped-from-githu