Struct cercis_html::VElement
source · pub struct VElement {
pub name: String,
pub attributes: Vec<Attribute>,
pub children: Vec<VNode>,
pub is_single: bool,
}
Fields§
§name: String
§attributes: Vec<Attribute>
§children: Vec<VNode>
§is_single: bool
Implementations§
source§impl VElement
impl VElement
pub fn new(element: impl Into<String>) -> Self
pub fn attr(self, attr: impl Into<Attribute>) -> Self
pub fn child(self, child: impl Into<VNode>) -> Self
pub fn merge(self, component: VBody) -> Self
pub fn node(self, child: impl Into<VNode>) -> Self
pub fn single(self) -> Self
pub fn render(&self) -> String
Trait Implementations§
Auto Trait Implementations§
impl Freeze for VElement
impl !RefUnwindSafe for VElement
impl !Send for VElement
impl !Sync for VElement
impl Unpin for VElement
impl !UnwindSafe for VElement
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