From 49df294db7ad5876fcfb849f376bbe7dda1be0f1 Mon Sep 17 00:00:00 2001 From: hophiphip Date: Mon, 9 Dec 2024 22:47:21 +0400 Subject: [PATCH] fix(react-virtual): run _didMount in useIsomorphicLayoutEffect --- packages/react-virtual/src/index.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/react-virtual/src/index.tsx b/packages/react-virtual/src/index.tsx index 3c4a4c98..d835e7c4 100644 --- a/packages/react-virtual/src/index.tsx +++ b/packages/react-virtual/src/index.tsx @@ -42,7 +42,7 @@ function useVirtualizerBase< instance.setOptions(resolvedOptions) - React.useEffect(() => { + useIsomorphicLayoutEffect(() => { return instance._didMount() }, [])