canonrs-server 0.1.0

CanonRS server-side rendering support
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
use leptos::prelude::*;

#[component]
pub fn CarouselItemPrimitive(
    #[prop(default = String::new())] class: String,
    #[prop(optional)] children: Option<Children>,
) -> impl IntoView {
    view! {
        <div
            class={class}
            attr:data-carousel-item=""
        >
            {children.map(|c| c())}
        </div>
    }
}