MCPcopy Create free account
hub / github.com/PerroEngine/Perro / BookChapterPage

Function BookChapterPage

perro_website/src/pages/docs.rs:104–117  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

102 }}
103 }
104}
105
106#[component]
107pub fn BookChapterPage() -> impl IntoView {
108 let params = use_params_map();
109 let slug = move || params.read().get("slug").unwrap_or_default();
110 let doc = move || find_doc("book", &slug());
111
112 view! {
113 {move || match doc() {
114 Some(doc) => view! {
115 <BookArticle doc=doc />
116 }.into_any(),
117 None => view! { <NotFound /> }.into_any(),
118 }}
119 }
120}

Callers

nothing calls this directly

Calls 3

find_docFunction · 0.85
getMethod · 0.45
readMethod · 0.45

Tested by

no test coverage detected