macro_rules! impl_props_builders {
($widget:ty) => { ... };
}Expand description
Generate builder methods for widgets with props: WidgetProps field.
This macro generates the following methods:
element_id(self, impl Into<String>) -> Self- Set CSS element IDclass(self, impl Into<String>) -> Self- Add a CSS classclasses(self, IntoIterator<Item=S>) -> Self- Add multiple CSS classes
§Example
ⓘ
struct MyWidget {
props: WidgetProps,
}
impl_props_builders!(MyWidget);