ui: fix legacy module load

This commit is contained in:
undefined committed 2023-04-12 22:10:10 +08:00
1 parent c92d03e204
commit aa044ee6d9
2 files changed
+2 -2

No files matched your search

@@ -39,7 +39,7 @@ const loaders = {
let apply = typeof item === 'function'
? item
: (item.startsWith('http') || item.startsWith('/'))
? await legacyLoadExternalModule(window.externalModules[item])
? await legacyLoadExternalModule(item)
: (await loadModule(item)).apply;
if (typeof apply !== 'function') apply = apply.default || apply.apply;
if (typeof apply === 'function') await apply(monaco);