diff --git a/src/views/dashboard/related/demand-log/Content.vue b/src/views/dashboard/related/demand-log/Content.vue index 75a549e0..51e3fc66 100644 --- a/src/views/dashboard/related/demand-log/Content.vue +++ b/src/views/dashboard/related/demand-log/Content.vue @@ -29,10 +29,9 @@ const demandLogStore = useDemandLogStore(); const monacoInstance = ref(); const logContent = ref>(null); -onMounted(() => { - import("monaco-editor/esm/vs/editor/editor.api").then((monaco) => { - monacoInstanceGen(monaco); - }); +onMounted(async () => { + const monaco = await import("monaco-editor/esm/vs/editor/editor.api"); + monacoInstanceGen(monaco); }); function monacoInstanceGen(monaco: any) { const value = demandLogStore.logs.map((d: Log) => d.content).join("\n");