Expand description
§leptosbook
SvelteKit-inspired gesture and book-navigation primitives for Leptos.
§Quick start
ⓘ
use leptosbook::prelude::*;
#[component]
fn App() -> impl IntoView {
let posts: Signal<Vec<Post>> = ...;
view! {
<Folio items=posts render=|p| view! { <PostCard post=p/> }>
// Anything here can call use_folio_context()
<FolioNav/>
</Folio>
}
}Re-exports§
pub use context::use_folio_context;pub use context::FolioContext;pub use context::TurnDir;pub use folio::Folio;pub use folio::FolioTabs;pub use gesture::resolve;pub use gesture::SwipeConfig;pub use gesture::SwipeDir;pub use install::InstallPrompt;
Modules§
Constants§
- FOLIO_
CSS - Default stylesheet. Inject with
<Style>{leptosbook::FOLIO_CSS}</Style>or let<Folio inject_css=true/>(the default) handle it automatically.