diff --git a/integrations/utils/src/lib.rs b/integrations/utils/src/lib.rs index 177f6aec2..b2b8be002 100644 --- a/integrations/utils/src/lib.rs +++ b/integrations/utils/src/lib.rs @@ -1,5 +1,5 @@ use futures::{stream::once, Stream, StreamExt}; -use hydration_context::SsrSharedContext; +use hydration_context::{SharedContext, SsrSharedContext}; use leptos::{ nonce::use_nonce, reactive_graph::owner::{Owner, Sandboxed}, @@ -81,7 +81,9 @@ pub fn build_response( where IV: IntoView + 'static, { - let owner = Owner::new_root(Some(Arc::new(SsrSharedContext::new()))); + let shared_context = Arc::new(SsrSharedContext::new()) + as Arc; + let owner = Owner::new_root(Some(Arc::clone(&shared_context))); let stream = Box::pin(Sandboxed::new({ let owner = owner.clone(); async move {