Skip to main content

live_node_for_element

Function live_node_for_element 

Source
pub fn live_node_for_element<H: UiHost>(
    app: &mut H,
    window: AppWindowId,
    element: GlobalElementId,
) -> Option<NodeId>
Expand description

Returns the current-frame node mapping for element, if available.

The authoritative liveness signal is the retained node_entry record being touched in the current frame (last_seen_frame == app.frame_id()). The declarative window-frame cache keeps stale records until subtree GC, so it must not be treated as a standalone liveness oracle.

Prefer this for render-time/component-policy code that needs a node that is still live for the current frame rather than a purely cross-frame cached mapping.