Closed Oleksii14 closed 2 months ago
Why would the default data point need adjustment, you are able to provide your own custom data types to chart.js:
import { Chart, ChartData } from 'chart.js';
var data: ChartData<'polarArea', {x: Date, y: {foo: boolean}}[]> = {
labels: [],
datasets: [{
data: [{ x: new Date(), y: {foo: false} }],
}],
};
var ctx = document.getElementById("myChart") as HTMLCanvasElement;
var myChart = new Chart(ctx, {
type: 'polarArea',
data: data,
});
Why would the default data point need adjustment, you are able to provide your own custom data types to chart.js:
import { Chart, ChartData } from 'chart.js'; var data: ChartData<'polarArea', {x: Date, y: {foo: boolean}}[]> = { labels: [], datasets: [{ data: [{ x: new Date(), y: {foo: "false"} }], }], }; var ctx = document.getElementById("myChart") as HTMLCanvasElement; var myChart = new Chart(ctx, { type: 'polarArea', data: data, });
You're right. The original issue should be resolved directly in the Vue.js implementation of the chart components. Thanks for the reply. I am closing this PR.
Original issue: https://github.com/apertureless/vue-chartjs/issues/1058