Skip to content

Commit

Permalink
[dynamicIO] unify cache filling and lazy-module warming
Browse files Browse the repository at this point in the history
We ended up with up to three prerender passes as we added support for new use cases like lazy module initializaiton. This update refactors the PPR pathway to have at most two renders.

I will follow up with a refactor of the non-ppr pathway next.
  • Loading branch information
gnoff committed Oct 23, 2024
1 parent 4d8fbe9 commit b3f77fc
Show file tree
Hide file tree
Showing 3 changed files with 203 additions and 208 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -77,12 +77,11 @@ export async function createReactServerPrerenderResult(
while (true) {
const { done, value } = await reader.read()
if (done) {
break
return new ReactServerPrerenderResult(chunks)
} else {
chunks.push(value)
}
}
return new ReactServerPrerenderResult(chunks)
}

export async function createReactServerPrerenderResultFromRender(
Expand Down
Loading

0 comments on commit b3f77fc

Please sign in to comment.