Skip to content

Commit 917c674

Browse files
committed
Clean up a node if we suspend after having rendering passed it
1 parent 8ddcae4 commit 917c674

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

packages/react-server/src/ReactFizzServer.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3099,6 +3099,9 @@ function replayElement(
30993099
if (task.node === currentNode) {
31003100
// This same element suspended so we need to pop the replay we just added.
31013101
task.replay = replay;
3102+
} else {
3103+
// We finished rendering this node, so now we can consume this slot.
3104+
replayNodes.splice(i, 1);
31023105
}
31033106
throw x;
31043107
}

0 commit comments

Comments
 (0)