From 5495aa8e014902209c66f3eb10a860890ff5fd2b Mon Sep 17 00:00:00 2001 From: Avin <48435155+avin-kavish@users.noreply.github.com> Date: Tue, 21 Mar 2023 20:29:23 +0530 Subject: [PATCH] Fix --- samples/browser-esm-vite-react/src/components/Editor.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/samples/browser-esm-vite-react/src/components/Editor.tsx b/samples/browser-esm-vite-react/src/components/Editor.tsx index c4010e6c3d..86992ec71c 100644 --- a/samples/browser-esm-vite-react/src/components/Editor.tsx +++ b/samples/browser-esm-vite-react/src/components/Editor.tsx @@ -9,7 +9,7 @@ export const Editor: VFC = () => { useEffect(() => { if (monacoEl) { setEditor((editor) => { - if (editor) return; + if (editor) return editor; return monaco.editor.create(monacoEl.current!, { value: ['function x() {', '\tconsole.log("Hello world!");', '}'].join('\n'),