Add server context to suspense resolution (#3552)

* Add server context to suspense resolution

While this was done correctly in the streaming case, non-streaming
suspense resolution didn't recieve the server context.  This meant that
anything that required the context after the point of suspension would
find it missing.

* fmt

---------

Co-authored-by: Jonathan Kelley <jkelleyrtp@gmail.com>
This commit is contained in:
James BenzeandJonathan Kelley authored and GitHub committed 2025-01-13 12:30:00 -08:00
1 parent 25a64d97c0
commit d5a04c69ba
1 file changed
+2 -1
+2 -1
View File
@@ -221,7 +221,8 @@ impl SsrRendererPool {
// If streaming is disabled, wait for the virtual dom to finish all suspense work
// before rendering anything
if streaming_mode == StreamingMode::Disabled {
virtual_dom.wait_for_suspense().await;
ProvideServerContext::new(virtual_dom.wait_for_suspense(), server_context.clone())
.await
}
// Render the initial frame with loading placeholders