MCPcopy
hub / github.com/plotly/dash / pushContextProvider

Function pushContextProvider

dash/deps/react-dom@18.2.0.js:11925–11939  ·  view source on GitHub ↗
(workInProgress)

Source from the content-addressed store, hash-verified

11923 }
11924
11925 function pushContextProvider(workInProgress) {
11926 {
11927 var instance = workInProgress.stateNode; // We push the context as early as possible to ensure stack integrity.
11928 // If the instance does not exist yet, we will push null at first,
11929 // and replace it on the stack later when invalidating the context.
11930
11931 var memoizedMergedChildContext = instance && instance.__reactInternalMemoizedMergedChildContext || emptyContextObject; // Remember the parent context so we can merge with it later.
11932 // Inherit the parent's did-perform-work value to avoid inadvertently blocking updates.
11933
11934 previousContext = contextStackCursor.current;
11935 push(contextStackCursor, memoizedMergedChildContext, workInProgress);
11936 push(didPerformWorkStackCursor, didPerformWorkStackCursor.current, workInProgress);
11937 return true;
11938 }
11939 }
11940
11941 function invalidateContextProvider(workInProgress, type, didChange) {
11942 {

Calls 1

pushFunction · 0.70

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…