n8n/packages/editor-ui/src/plugins/chartjs.ts
कारतोफ्फेलस्क्रिप्ट™ ebee1a5908
fix(editor): Make sure LineController is registered with chart.js (#7730)
Tree shaking in production build of the editor-ui package removed the
LineController, this makes sure it is in the final package.
2023-11-16 11:57:43 +01:00

29 lines
379 B
TypeScript

import {
Chart as ChartJS,
Title,
Tooltip,
Legend,
BarElement,
LineElement,
PointElement,
CategoryScale,
LinearScale,
LineController,
} from 'chart.js';
export const ChartJSPlugin = {
install: () => {
ChartJS.register(
CategoryScale,
LinearScale,
BarElement,
LineElement,
PointElement,
Title,
Tooltip,
Legend,
LineController,
);
},
};