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

Function createFiberFromPortal

code/new-context-api/public/app.js:6434–6444  ·  view source on GitHub ↗
(portal, mode, expirationTime)

Source from the content-addressed store, hash-verified

6432}
6433
6434function createFiberFromPortal(portal, mode, expirationTime) {
6435 var pendingProps = portal.children !== null ? portal.children : [];
6436 var fiber = createFiber(HostPortal, pendingProps, portal.key, mode);
6437 fiber.expirationTime = expirationTime;
6438 fiber.stateNode = {
6439 containerInfo: portal.containerInfo,
6440 pendingChildren: null, // Used by persistent updates
6441 implementation: portal.implementation
6442 };
6443 return fiber;
6444}
6445
6446// TODO: This should be lifted into the renderer.
6447

Callers 3

updatePortalFunction · 0.70
createChildFunction · 0.70
reconcileSinglePortalFunction · 0.70

Calls 1

createFiberFunction · 0.70

Tested by

no test coverage detected