Clean up a number of examples

This commit is contained in:
Jonathan Kelley committed 2024-01-15 13:06:05 -08:00
1 parent f2caa3a3ad
commit 6134a2ce24
30 files changed
+284 -413

No files matched your search

+4 -4
View File
@@ -12,13 +12,13 @@ fn app() -> Element {
}
}
#[derive(PartialEq, Props)]
struct GenericChildProps<T: Display + PartialEq> {
#[derive(PartialEq, Props, Clone)]
struct GenericChildProps<T: Display + PartialEq + Clone + 'static> {
data: T,
}
fn generic_child<T: Display + PartialEq>(cx: Scope<GenericChildProps<T>>) -> Element {
fn generic_child<T: Display + PartialEq + Clone>(props: GenericChildProps<T>) -> Element {
render! {
div { "{&cx.props.data}" }
div { "{&props.data}" }
}
}