Skip to content

Commit 71f9710

Browse files
authored
fix: re-integrate excalidrawAPI into window object (#43)
1 parent bb7a3be commit 71f9710

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

src/frontend/src/App.tsx

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,16 @@ export default function App({
5555
}
5656
});
5757

58+
59+
useEffect(() => {
60+
if (excalidrawAPI) {
61+
(window as any).excalidrawAPI = excalidrawAPI;
62+
}
63+
return () => {
64+
(window as any).excalidrawAPI = null;
65+
};
66+
}, [excalidrawAPI]);
67+
5868
const lastSentCanvasDataRef = useRef<string>("");
5969

6070
const debouncedLogChange = useCallback(

0 commit comments

Comments
 (0)