From 7c9ffeacc3cc9f577f9fb68dd1b9d86596bbc8c0 Mon Sep 17 00:00:00 2001 From: Quentin Date: Thu, 4 Sep 2025 22:11:55 +0200 Subject: [PATCH] fix: add missing dependencies to hooks --- src/components/Application.tsx | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) diff --git a/src/components/Application.tsx b/src/components/Application.tsx index aaf34bc0..b4462557 100644 --- a/src/components/Application.tsx +++ b/src/components/Application.tsx @@ -94,7 +94,7 @@ const ApplicationImplementation = forwardRef(f applicationRef.current = application; updateResizeTo(); onInit?.(application); - }, [onInit]); + }, [onInit, updateResizeTo]); useIsomorphicLayoutEffect(() => { @@ -144,17 +144,12 @@ const ApplicationImplementation = forwardRef(f // @ts-expect-error The value of `children` is fine, but `PixiReactChildNode` doesn't strictly adhere to the `ReactNode` structure. root.render(({children}), applicationProps); } - }, [ - applicationProps, - children, - handleInit, - resizeTo, - ]); + }, [Bridge, applicationProps, children, handleInit, resizeTo]); useIsomorphicLayoutEffect(() => { updateResizeTo(); - }, [resizeTo]); + }, [updateResizeTo]); useIsomorphicLayoutEffect(() => {