perf: 优化性能,去除组件中多余注册内容

This commit is contained in:
奔跑的面条
2022-09-27 20:02:35 +08:00
parent 617b940d64
commit 972c92519c
3 changed files with 7 additions and 16 deletions
@@ -15,13 +15,12 @@ import VChart from 'vue-echarts'
import 'echarts-wordcloud'
import { use } from 'echarts/core'
import { CanvasRenderer } from 'echarts/renderers'
import { BarChart } from 'echarts/charts'
import config, { includes } from './config'
import { mergeTheme } from '@/packages/public/chart'
import { useChartDataFetch } from '@/hooks'
import { useChartEditStore } from '@/store/modules/chartEditStore/chartEditStore'
import { isPreview } from '@/utils'
import { GridComponent, TooltipComponent, LegendComponent } from 'echarts/components'
import { GridComponent, TooltipComponent } from 'echarts/components'
import dataJson from './data.json'
const props = defineProps({
@@ -39,7 +38,7 @@ const props = defineProps({
}
})
use([CanvasRenderer, BarChart, GridComponent, TooltipComponent, LegendComponent])
use([CanvasRenderer, GridComponent, TooltipComponent])
const replaceMergeArr = ref<string[]>()