MCPcopy Index your code
hub / github.com/react/react / prepareToUseHooksForComponent

Function prepareToUseHooksForComponent

packages/react-server/src/ReactFlightHooks.js:35–44  ·  view source on GitHub ↗
(
  prevThenableState: ThenableState | null,
  componentDebugInfo: null | ReactComponentInfo,
)

Source from the content-addressed store, hash-verified

33}
34
35export function prepareToUseHooksForComponent(
36 prevThenableState: ThenableState | null,
37 componentDebugInfo: null | ReactComponentInfo,
38) {
39 thenableIndexCounter = 0;
40 thenableState = prevThenableState;
41 if (__DEV__) {
42 currentComponentDebugInfo = componentDebugInfo;
43 }
44}
45
46export function getThenableStateAfterSuspending(): ThenableState {
47 // If you use() to Suspend this should always exist but if you throw a Promise instead,

Callers 1

renderFunctionComponentFunction · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected