Bring back mroe hooks, remove old hooks, cleanup a number of examples

This commit is contained in:
Jonathan Kelley committed 2024-01-15 17:04:39 -08:00
1 parent b291a5c0b0
commit 74aa55f85f
33 files changed
+179 -643

No files matched your search

+7 -7
View File
@@ -35,7 +35,7 @@ fn app() -> Element {
type SthElse<T> = Option<T>;
#[derive(Props, PartialEq)]
#[derive(Props, PartialEq, Clone)]
struct ButtonProps {
a: String,
@@ -51,14 +51,14 @@ struct ButtonProps {
e: SthElse<String>,
}
fn Button(cx: Scope<ButtonProps>) -> Element {
fn Button(props: ButtonProps) -> Element {
rsx! {
button {
"{cx.props.a} | "
"{cx.props.b:?} | "
"{cx.props.c:?} | "
"{cx.props.d:?} | "
"{cx.props.e:?}"
"{props.a} | "
"{props.b:?} | "
"{props.c:?} | "
"{props.d:?} | "
"{props.e:?}"
}
}
}