LoongPanel-Asp/web/plugins/echarts.ts

22 lines
750 B
TypeScript
Raw Normal View History

2024-06-22 10:54:02 +08:00
import {use} from 'echarts/core';
// import ECharts modules manually to reduce bundle size
import {CanvasRenderer} from 'echarts/renderers';
import {BarChart, GaugeChart, LineChart, LinesChart, PieChart} from 'echarts/charts';
import {
GridComponent,
TooltipComponent,
ToolboxComponent,
TimelineComponent,
SingleAxisComponent,
CalendarComponent,
AriaComponent,
BrushComponent,
TitleComponent,
LegendComponent,
DataZoomComponent
} from 'echarts/components';
export default defineNuxtPlugin(() => {
use([CanvasRenderer, BarChart, GaugeChart, LinesChart, LineChart, PieChart, GridComponent, TooltipComponent, ToolboxComponent, TimelineComponent, TitleComponent, LegendComponent, DataZoomComponent]);
});