[][src]Struct virtual_dom_rs::VElement

pub struct VElement {
    pub tag: String,
    pub attrs: HashMap<String, String, RandomState>,
    pub events: Events,
    pub children: Vec<VirtualNode>,
}

Fields

tag: String

The HTML tag, such as "div"

attrs: HashMap<String, String, RandomState>

HTML attributes such as id, class, style, etc

events: Events

Events that will get added to your real DOM element via .addEventListener

children: Vec<VirtualNode>

The children of this VirtualNode. So a

structure would have a parent div and one child, em.

Implementations

impl VElement[src]

pub fn new<S>(tag: S) -> VElement where
    S: Into<String>, 
[src]

pub fn create_element_node(&self) -> CreatedNode<Element>[src]

Build a DOM element by recursively creating DOM nodes for this element and it's children, it's children's children, etc.

Trait Implementations

impl Debug for VElement[src]

impl Display for VElement[src]

impl From<VElement> for VirtualNode[src]

impl PartialEq<VElement> for VElement[src]

impl StructuralPartialEq for VElement[src]

Auto Trait Implementations

impl !RefUnwindSafe for VElement

impl !Send for VElement

impl !Sync for VElement

impl Unpin for VElement

impl !UnwindSafe for VElement

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToString for T where
    T: Display + ?Sized
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.