pub enum ChildrenSpec {
Empty,
Text(String),
Slot(String),
Slots(Vec<String>),
Children,
Elements(Vec<RenderOutput>),
}Expand description
Specification for component children.
Components can render different types of children — slots, text, or delegate to the consumer.
Variants§
Empty
No children.
Text(String)
Static text content.
Slot(String)
Named slot — the consumer provides content for this slot.
Slots(Vec<String>)
Multiple named slots.
Children
Consumer-provided children (the default for most components).
Elements(Vec<RenderOutput>)
Multiple child render outputs (compound components).
Trait Implementations§
Source§impl Clone for ChildrenSpec
impl Clone for ChildrenSpec
Source§fn clone(&self) -> ChildrenSpec
fn clone(&self) -> ChildrenSpec
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for ChildrenSpec
impl Debug for ChildrenSpec
Source§impl Default for ChildrenSpec
impl Default for ChildrenSpec
Source§fn default() -> ChildrenSpec
fn default() -> ChildrenSpec
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for ChildrenSpec
impl<'de> Deserialize<'de> for ChildrenSpec
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl PartialEq for ChildrenSpec
impl PartialEq for ChildrenSpec
Source§impl Serialize for ChildrenSpec
impl Serialize for ChildrenSpec
impl StructuralPartialEq for ChildrenSpec
Auto Trait Implementations§
impl Freeze for ChildrenSpec
impl RefUnwindSafe for ChildrenSpec
impl Send for ChildrenSpec
impl Sync for ChildrenSpec
impl Unpin for ChildrenSpec
impl UnsafeUnpin for ChildrenSpec
impl UnwindSafe for ChildrenSpec
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