From 9743db8886aee1e1e12eca99231e957704e1815f Mon Sep 17 00:00:00 2001 From: Leroy Korterink Date: Wed, 11 Oct 2023 13:27:42 +0200 Subject: [PATCH] Update previousChildren when they are equal --- .../src/TransitionPresence/TransitionPresence.tsx | 1 + 1 file changed, 1 insertion(+) diff --git a/packages/react-transition-presence/src/TransitionPresence/TransitionPresence.tsx b/packages/react-transition-presence/src/TransitionPresence/TransitionPresence.tsx index e4c666a..e991668 100644 --- a/packages/react-transition-presence/src/TransitionPresence/TransitionPresence.tsx +++ b/packages/react-transition-presence/src/TransitionPresence/TransitionPresence.tsx @@ -64,6 +64,7 @@ export function TransitionPresence({ useEffect(() => { if (childrenAreEqual(children, previousChildren)) { + setPreviousChildren(children); return; }