forked from github/dataease
commit
ea72262b28
@ -54,15 +54,13 @@ export default {
|
||||
// window.SyncComponentCache[this.url] = Axios.get(this.url)
|
||||
res = await window.SyncComponentCache[this.url]
|
||||
} else {
|
||||
this.mode = await window.SyncComponentCache[this.url]
|
||||
return
|
||||
res = await window.SyncComponentCache[this.url]
|
||||
}
|
||||
if (res) {
|
||||
const Fn = Function
|
||||
const dynamicCode = res.data || res
|
||||
const component = new Fn(`return ${dynamicCode}`)()
|
||||
this.mode = component.default || component
|
||||
window.SyncComponentCache[this.url] = this.mode
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user