hcong
2024-11-08 d7d7da5c09340eafcd2e2c672e6b2c001a4cc0be
src/main.js
@@ -14,6 +14,10 @@
import 'element-plus/theme-chalk/src/message-box.scss';
import 'element-plus/theme-chalk/src/notification.scss';
// 引入echarts
// import Echarts from 'vue-echarts'
import * as echarts from 'echarts'
// dayjs plugin
import dayjs from 'dayjs';
import isSameOrAfter from 'dayjs/plugin/isSameOrAfter';
@@ -29,7 +33,10 @@
for (const [key, component] of Object.entries(ElementPlusIconsVue)) {
  app.component(key, component);
}
// 使用组件
// app.component('e-charts',Echarts)
// 全局挂载 echarts
app.config.globalProperties.$echarts = echarts
app
  .use(pinia)
  .use(router)