1
0
Fork 0

simpler render syntax

Zynh Ludwig 2024-08-30 23:06:13 -07:00
parent c9aac19f8b
commit 7f62c9b6a8
2 changed files with 2 additions and 6 deletions

View File

@ -28,9 +28,7 @@ async fn link(
{
return Ok(Html(ssr::render({
let record = record.clone();
|| {
leptos::view! { <DownloadLinkPage id=id record=record /> }
}
|| leptos::view! { <DownloadLinkPage id=id record=record /> }
})));
}
}

View File

@ -92,9 +92,7 @@ async fn upload_to_zip(
.status(200)
.header("Content-Type", "text/html")
.header("HX-Push-Url", format!("/link/{}", &id))
.body(ssr::render(|| {
leptos::view! { <LinkView id record /> }
}))
.body(ssr::render(|| leptos::view! { <LinkView id record /> }))
.unwrap();
Ok(response)