MCPcopy Create free account
hub / github.com/krasimir/react-in-patterns / detachFiber

Function detachFiber

code/communication/public/app.js:11536–11548  ·  view source on GitHub ↗
(current)

Source from the content-addressed store, hash-verified

11534 }
11535
11536 function detachFiber(current) {
11537 // Cut off the return pointers to disconnect it from the tree. Ideally, we
11538 // should clear the child pointer of the parent alternate to let this
11539 // get GC:ed but we don't know which for sure which parent is the current
11540 // one so we'll settle for GC:ing the subtree of this child. This child
11541 // itself will be GC:ed when the parent updates the next time.
11542 current['return'] = null;
11543 current.child = null;
11544 if (current.alternate) {
11545 current.alternate.child = null;
11546 current.alternate['return'] = null;
11547 }
11548 }
11549
11550 var emptyPortalContainer = void 0;
11551

Callers 2

ReactFiberCommitWorkFunction · 0.70
commitDeletionFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected