pub struct VElement<'a> {
    pub id: Cell<Option<ElementId>>,
    pub key: Option<&'a str>,
    pub tag: &'static str,
    pub namespace: Option<&'static str>,
    pub parent: Cell<Option<ElementId>>,
    pub listeners: &'a [Listener<'a>],
    pub attributes: &'a [Attribute<'a>],
    pub children: &'a [VNode<'a>],
}
Expand description

An element like a “div” with children, listeners, and attributes.

Fields

id: Cell<Option<ElementId>>

The ElementId of the VText.

key: Option<&'a str>

The key of the element to be used during keyed diffing.

tag: &'static str

The tag name of the element.

IE “div”

namespace: Option<&'static str>

The namespace of the VElement

IE “svg”

parent: Cell<Option<ElementId>>

The parent of the Element (if any).

Used when bubbling events

listeners: &'a [Listener<'a>]

The Listeners of the VElement.

attributes: &'a [Attribute<'a>]

The attributes of the VElement.

children: &'a [VNode<'a>]

The children of the VElement.

Trait Implementations

Formats the value using the given formatter. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.