MCPcopy
hub / github.com/facebook/react / createPendingSegment

Function createPendingSegment

packages/react-server/src/ReactFizzServer.js:955–976  ·  view source on GitHub ↗
(
  request: Request,
  index: number,
  boundary: null | SuspenseBoundary,
  parentFormatContext: FormatContext,
  lastPushedText: boolean,
  textEmbedded: boolean,
)

Source from the content-addressed store, hash-verified

953}
954
955function createPendingSegment(
956 request: Request,
957 index: number,
958 boundary: null | SuspenseBoundary,
959 parentFormatContext: FormatContext,
960 lastPushedText: boolean,
961 textEmbedded: boolean,
962): Segment {
963 return {
964 status: PENDING,
965 parentFlushed: false,
966 id: -1, // lazily assigned later
967 index,
968 chunks: [],
969 children: [],
970 preambleChildren: [],
971 parentFormatContext,
972 boundary,
973 lastPushedText,
974 textEmbedded,
975 };
976}
977
978function getCurrentStackInDEV(): string {
979 if (__DEV__) {

Callers 8

createRequestFunction · 0.85
resumeRequestFunction · 0.85
renderSuspenseBoundaryFunction · 0.85
renderSuspenseListRowsFunction · 0.85
renderPreambleFunction · 0.85
resumeNodeFunction · 0.85
injectPostponedHoleFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected