dillon1000/react

Commit

Handle unmounted and not-yet-inserted subtrees in isMounted

There are two cases where we have a Fiber that is not actually
mounted. Either it is part of a tree that has not yet been
inserted or it is part of a tree that was unmounted.

For the insertion case, we can check the parents to see if there
is any insertion effect pending along the parent path.

For deletions, we can now check if any of the return pointers
is null without actually being the root.
Browse files
Changed paths4 files
First-parent comparison
M src/renderers/shared/fiber/ReactFiberCommitWork.js ModifiedM src/renderers/shared/fiber/ReactFiberScheduler.js ModifiedM src/renderers/shared/fiber/ReactFiberTreeReflection.js ModifiedA src/renderers/shared/fiber/__tests__/ReactIncrementalReflection-test.js Added
Patch

Files changed

Rendering syntax-highlighted changes…