MCPcopy Index your code
hub / github.com/caseywebdev/react-list / completeWork

Function completeWork

docs/index.js:13178–13607  ·  view source on GitHub ↗
(current, workInProgress, renderLanes)

Source from the content-addressed store, hash-verified

13176 return didBailout;
13177}
13178function completeWork(current, workInProgress, renderLanes) {
13179 var newProps = workInProgress.pendingProps;
13180 popTreeContext(workInProgress);
13181 switch (workInProgress.tag) {
13182 case 16:
13183 case 15:
13184 case 0:
13185 case 11:
13186 case 7:
13187 case 8:
13188 case 12:
13189 case 9:
13190 case 14:
13191 return bubbleProperties(workInProgress), null;
13192 case 1:
13193 return bubbleProperties(workInProgress), null;
13194 case 3:
13195 renderLanes = workInProgress.stateNode;
13196 newProps = null;
13197 null !== current && (newProps = current.memoizedState.cache);
13198 workInProgress.memoizedState.cache !== newProps &&
13199 (workInProgress.flags |= 2048);
13200 popProvider(CacheContext);
13201 popHostContainer();
13202 renderLanes.pendingContext &&
13203 ((renderLanes.context = renderLanes.pendingContext),
13204 (renderLanes.pendingContext = null));
13205 if (null === current || null === current.child)
13206 popHydrationState(workInProgress)
13207 ? markUpdate(workInProgress)
13208 : null === current ||
13209 (current.memoizedState.isDehydrated &&
13210 0 === (workInProgress.flags & 256)) ||
13211 ((workInProgress.flags |= 1024),
13212 null !== hydrationErrors &&
13213 (queueRecoverableErrors(hydrationErrors),
13214 (hydrationErrors = null)));
13215 bubbleProperties(workInProgress);
13216 return null;
13217 case 26:
13218 return (
13219 (renderLanes = workInProgress.memoizedState),
13220 null === current
13221 ? (markUpdate(workInProgress),
13222 null !== renderLanes
13223 ? (bubbleProperties(workInProgress),
13224 preloadResourceAndSuspendIfNeeded(workInProgress, renderLanes))
13225 : (bubbleProperties(workInProgress),
13226 (workInProgress.flags &= -16777217)))
13227 : renderLanes
13228 ? renderLanes !== current.memoizedState
13229 ? (markUpdate(workInProgress),
13230 bubbleProperties(workInProgress),
13231 preloadResourceAndSuspendIfNeeded(workInProgress, renderLanes))
13232 : (bubbleProperties(workInProgress),
13233 (workInProgress.flags &= -16777217))
13234 : (current.memoizedProps !== newProps && markUpdate(workInProgress),
13235 bubbleProperties(workInProgress),

Callers 1

completeUnitOfWorkFunction · 0.85

Calls 15

popTreeContextFunction · 0.85
bubblePropertiesFunction · 0.85
popProviderFunction · 0.85
popHostContainerFunction · 0.85
popHydrationStateFunction · 0.85
markUpdateFunction · 0.85
queueRecoverableErrorsFunction · 0.85
popHostContextFunction · 0.85
formatProdErrorMessageFunction · 0.85
resolveSingletonInstanceFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…