Merge pull request #1674 from ealmloff/better-optional-props

Make optional props accept Nothing, T or Option<T>
This commit is contained in:
Jonathan Kelley authored and GitHub committed 2023-12-06 21:37:39 -08:00
commit f2504cec84
2 files changed
+21 -28

No files matched your search

+12
View File
@@ -16,8 +16,20 @@ fn app(cx: Scope) -> Element {
a: "asd".to_string(),
c: "asd".to_string(),
d: Some("asd".to_string()),
e: Some("asd".to_string()),
}
Button {
a: "asd".to_string(),
b: "asd".to_string(),
c: "asd".to_string(),
d: Some("asd".to_string()),
e: "asd".to_string(),
}
Button {
a: "asd".to_string(),
c: "asd".to_string(),
d: Some("asd".to_string()),
}
})
}