pub enum Child<'a> {
Text(&'a str),
ComponentVec(Vec<Box<Component<'a>>>),
NoChild,
}
Expand description
What is to be placed inside the HTML component.
This could be:
text, e.g. Child::Text("Hello World")
creates a <div>Hello World</div>
component;
a vector of other components (Child::ComponentVec(vec![Box::new(Component {...})])
); or
nothing (Child::NoChild
)
Variants§
Auto Trait Implementations§
impl<'a> Freeze for Child<'a>
impl<'a> RefUnwindSafe for Child<'a>
impl<'a> Send for Child<'a>
impl<'a> Sync for Child<'a>
impl<'a> Unpin for Child<'a>
impl<'a> UnwindSafe for Child<'a>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more