#[repr(C)]pub struct NodeDataExt {
pub attributes: AttributeTypeVec,
pub virtual_view: Option<VirtualViewNode>,
pub dataset: Option<RefAny>,
pub svg_data: Option<SvgNodeData>,
pub menu_bar: Option<Box<Menu>>,
pub context_menu: Option<Box<Menu>>,
pub key: Option<u64>,
pub dataset_merge_callback: Option<DatasetMergeCallback>,
pub component_origin: Option<ComponentOrigin>,
}Expand description
NOTE: NOT EXPOSED IN THE API! Stores extra,
not commonly used information for the NodeData.
This helps keep the primary NodeData struct smaller for common cases.
Fields§
§attributes: AttributeTypeVecStrongly-typed HTML attributes (aria-*, href, alt, etc.)
IDs and classes are stored as AttributeType::Id and AttributeType::Class entries.
Moved from NodeData to save 48B for the ~95% of nodes with no attributes.
virtual_view: Option<VirtualViewNode>VirtualView callback data, only set when node_type == NodeType::VirtualView.
dataset: Option<RefAny>data-* attributes for this node, useful to store UI-related data on the node itself.
svg_data: Option<SvgNodeData>SVG-specific data or raster clip mask for this DOM node.
Menu bar that should be displayed at the top of this nodes rect.
Context menu that should be opened when the item is left-clicked.
key: Option<u64>Stable key for reconciliation. If provided, allows the framework to track this node across frames even if its position in the array changes. This is crucial for correct lifecycle events when lists are reordered.
dataset_merge_callback: Option<DatasetMergeCallback>Callback to merge dataset state from a previous frame’s node into the current node. This enables heavy resource preservation (video decoders, GL textures) across frames.
component_origin: Option<ComponentOrigin>Tracks which component rendered this DOM subtree. Set by the framework during component rendering — the root node(s) of a component’s output DOM get stamped with the component’s qualified name. Enables the debugger to reconstruct the component invocation tree from the flat rendered DOM, and enables code generation roundtrips.
Trait Implementations§
Source§impl Clone for NodeDataExt
impl Clone for NodeDataExt
Source§fn clone(&self) -> NodeDataExt
fn clone(&self) -> NodeDataExt
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for NodeDataExt
impl Debug for NodeDataExt
Source§impl Default for NodeDataExt
impl Default for NodeDataExt
Source§fn default() -> NodeDataExt
fn default() -> NodeDataExt
Source§impl Hash for NodeDataExt
impl Hash for NodeDataExt
Source§impl Ord for NodeDataExt
impl Ord for NodeDataExt
Source§fn cmp(&self, other: &NodeDataExt) -> Ordering
fn cmp(&self, other: &NodeDataExt) -> Ordering
1.21.0 (const: unstable) · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Source§impl PartialEq for NodeDataExt
impl PartialEq for NodeDataExt
Source§fn eq(&self, other: &NodeDataExt) -> bool
fn eq(&self, other: &NodeDataExt) -> bool
self and other values to be equal, and is used by ==.