Expand description
MusKitty DOM
实现 DOM Living Standard 的核心节点类型与树操作 API。
§模块结构
node:Node、NodeType、NodeKind、Descendantselement/text/comment/document/document_type/document_fragment:各节点类型的数据载体attribute:Attribute、Namespacetree:树修改算法(append_child/insert_before/remove_child/replace_child)event:事件模型(Event、add_event_listener/dispatch_event)error:DomError
§参考
- DOM Living Standard: https://dom.spec.whatwg.org/
Re-exports§
pub use attribute::Attribute;pub use attribute::Namespace;pub use comment::CommentData;pub use document::DocumentData;pub use document_fragment::DocumentFragmentData;pub use document_type::DocumentTypeData;pub use element::ElementData;pub use error::DomError;pub use event::add_event_listener;pub use event::dispatch_event;pub use event::remove_event_listener;pub use event::Event;pub use event::EventCallback;pub use event::EventListenerOptions;pub use event::EventPhase;pub use node::Descendants;pub use node::Node;pub use node::NodeKind;pub use node::NodeType;pub use processing_instruction::ProcessingInstructionData;pub use text::TextData;pub use tree::adopt_node;pub use tree::append_child;pub use tree::clone_node;pub use tree::drain_children;pub use tree::insert_before;pub use tree::normalize;pub use tree::push_child_raw;pub use tree::remove_child;pub use tree::replace_child;pub use tree::retain_children;pub use tree::set_text_content;
Modules§
- attribute
- HTML/DOM 属性与命名空间类型。
- comment
- Comment 节点数据。
- document
- Document 节点数据。
- document_
fragment - DocumentFragment 节点数据。
- document_
type - DocumentType 节点数据。
- element
- Element 节点数据。
- error
- DOM 操作错误类型。
- event
- DOM 事件模型(DOM Living Standard §4.4 / §4.5 / §4.6)。
- node
- DOM 节点核心类型。
- processing_
instruction - ProcessingInstruction 节点数据。
- text
- Text 节点数据。
- tree
- DOM 树操作(mutation)算法。