This commit is contained in:
Greg Johnston
2025-11-10 20:59:06 -05:00
parent 8c3c3d8292
commit 4c1b1eeba2
2 changed files with 6 additions and 7 deletions

View File

@@ -10,7 +10,7 @@ crate-type = ["cdylib", "rlib"]
axum = { version = "0.8.1", optional = true }
console_error_panic_hook = "0.1.7"
console_log = "1.0"
leptos = { path = "../../leptos", features = ["tracing"] }
leptos = { path = "../../leptos", features = ["tracing", "lazy"] }
leptos_meta = { path = "../../meta" }
leptos_axum = { path = "../../integrations/axum", optional = true }
leptos_router = { path = "../../router" }

View File

@@ -593,12 +593,11 @@ impl RenderHtml for AnyView {
}
#[cfg(all(feature = "hydrate", feature = "lazy"))]
{
_ = cursor;
_ = position;
panic!(
"you have the `lazy` feature enabled, but are using regular \
hydration; use `hydrate_lazy()` instead"
);
use futures::FutureExt;
(self.hydrate_async)(self.value, cursor, position)
.now_or_never()
.unwrap()
}
#[cfg(not(feature = "hydrate"))]
{