Skip to content

Commit

Permalink
Use pending props instead of memoizedProps
Browse files Browse the repository at this point in the history
  • Loading branch information
sammy-SC committed Oct 11, 2022
1 parent 3c71140 commit 3baca4e
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion packages/react-reconciler/src/ReactFiberCommitWork.new.js
Original file line number Diff line number Diff line change
Expand Up @@ -2801,7 +2801,7 @@ function commitMutationEffectsOnFiber(
}

// Offscreen with manual mode manages visibility manually.
if (supportsMutation && finishedWork.memoizedProps.mode !== 'manual') {
if (supportsMutation && finishedWork.pendingProps.mode !== 'manual') {
// TODO: This needs to run whenever there's an insertion or update
// inside a hidden Offscreen tree.
hideOrUnhideAllChildren(offscreenBoundary, isHidden);
Expand Down
2 changes: 1 addition & 1 deletion packages/react-reconciler/src/ReactFiberCommitWork.old.js
Original file line number Diff line number Diff line change
Expand Up @@ -2801,7 +2801,7 @@ function commitMutationEffectsOnFiber(
}

// Offscreen with manual mode manages visibility manually.
if (supportsMutation && finishedWork.memoizedProps.mode !== 'manual') {
if (supportsMutation && finishedWork.pendingProps.mode !== 'manual') {
// TODO: This needs to run whenever there's an insertion or update
// inside a hidden Offscreen tree.
hideOrUnhideAllChildren(offscreenBoundary, isHidden);
Expand Down

0 comments on commit 3baca4e

Please sign in to comment.