mirror of
https://gitee.com/dromara/go-view.git
synced 2026-04-23 00:00:12 +08:00
fix: 修改类型报错
This commit is contained in:
@@ -10,15 +10,16 @@ import { CreateComponentType } from '@/packages/index.d'
|
||||
* @param app
|
||||
*/
|
||||
export const setupPreviewPackages = (app: App) => {
|
||||
if(!document.location.hash.includes('preview')) return
|
||||
const localStorageInfo = getLocalStorageInfo()
|
||||
if(!localStorageInfo) return
|
||||
localStorageInfo.componentList.forEach(async (e: CreateComponentType) => {
|
||||
if (!app.component(e.key)) {
|
||||
const chart = fetchChartComponent(e.chartConfig)
|
||||
app.component(e.key, chart)
|
||||
}
|
||||
})
|
||||
if (document.location.hash.includes('preview')) {
|
||||
const localStorageInfo = getLocalStorageInfo()
|
||||
if (!localStorageInfo) return
|
||||
localStorageInfo.componentList.forEach(async (e: CreateComponentType) => {
|
||||
if (!app.component(e.key)) {
|
||||
const chart = fetchChartComponent(e.chartConfig)
|
||||
app.component(e.key, chart)
|
||||
}
|
||||
})
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user