diff --git a/code-editor/src/App.tsx b/code-editor/src/App.tsx index 242ec69..2a8d28b 100644 --- a/code-editor/src/App.tsx +++ b/code-editor/src/App.tsx @@ -58,6 +58,14 @@ function App() { beforeMount={async (monaco: Monaco) => { shikiToMonaco(await highlighter, monaco); }} + onChange={(value) => { + if (value !== undefined) { + window.parent.postMessage( + { type: "editor-info", language, code: value }, + "*" + ); + } + }} />