Skip to main content

euv_core/renderer/render/
struct.rs

1use crate::*;
2
3/// Manages the rendering of virtual DOM nodes to the real DOM.
4///
5/// Maintains a mapping between virtual nodes and real DOM elements,
6/// and handles creation, diffing, and patching of the DOM tree.
7#[derive(CustomDebug, Data)]
8pub struct Renderer {
9    /// The root DOM element.
10    #[debug(skip)]
11    #[get(pub(crate))]
12    #[set(pub(crate))]
13    pub(crate) root: Element,
14    /// The current virtual DOM tree.
15    #[debug(skip)]
16    #[get(pub(crate))]
17    #[set(pub(crate))]
18    pub(crate) current_tree: Option<VirtualNode>,
19}