bindings/dom library

Classes

AbortController
The interface represents a controller object that allows you to abort one or more Web requests as and when desired. You can create a new object using the AbortController() constructor. Communicating with a DOM request is done using an AbortSignal object.
AbortSignal
The interface represents a signal object that allows you to communicate with a DOM request (such as a fetch request) and abort it if required via an AbortController object.
AbstractRange
The abstract interface is the base class upon which all DOM range types are defined. A range is an object that indicates the start and end points of a section of content within the document.
AddEventListenerOptions
Attr
The interface represents one of an element's attributes as an object. In most situations, you will directly retrieve the attribute value as a string (e.g., Element.getAttribute()), but certain functions (e.g., Element.getAttributeNode()) or means of iterating return instances. The core idea of an object of type is the association between a name and a value. An attribute may also be part of a namespace and, in this case, it also has a URI identifying the namespace, and a prefix that is an abbreviation for the namespace. The name is deemed local when it ignores the eventual namespace prefix and deemed qualified when it includes the prefix of the namespace, if any, separated from the local name by a colon (:). We have three cases: an attribute outside of a namespace, an attribute inside a namespace without a prefix defined, an attribute inside a namespace with a prefix:
CDATASection
The interface represents a CDATA section that can be used within XML to include extended portions of unescaped text. When inside a CDATA section, the symbols < and & don't need escaping as they normally do.
CharacterData
The abstract interface represents a Node object that contains characters. This is an abstract interface, meaning there aren't any objects of type : it is implemented by other interfaces like Text, Comment, CDATASection, or ProcessingInstruction, which aren't abstract.
ChildNode
Comment
The interface represents textual notations within markup; although it is generally not visually shown, such comments are available to be read in the source view. Comments are represented in HTML and XML as content between '<!--]' and '[-->'. In XML, like inside SVG or MathML markup, the character sequence '--' cannot be used within a comment.
CustomEvent
The interface represents events initialized by an application for any purpose. Note: This feature is available in Web Workers
CustomEventInit
Document
The interface represents any web page loaded in the browser and serves as an entry point into the web page's content, which is the DOM tree. The DOM tree includes elements such as <body> and <table>, among many others. It provides functionality globally to the document, like how to obtain the page's URL and create new elements in the document.
DocumentFragment
The interface represents a minimal document object that has no parent. It is used as a lightweight version of Document that stores a segment of a document structure comprised of nodes just like a standard document. The key difference is due to the fact that the document fragment isn't part of the active document tree structure. Changes made to the fragment don't affect the document (even on reflow) or incur any performance impact when changes are made.
DocumentOrShadowRoot
DocumentType
The interface represents a Node containing a doctype.
DOMImplementation
The interface represents an object providing methods which are not dependent on any particular document. Such an object is returned by the Document.implementation property.
DOMTokenList
The interface represents a set of space-separated tokens. Such a set is returned by Element.classList or HTMLLinkElement.relList, and many others. A is indexed beginning with 0 as with JavaScript Array objects. is always case-sensitive.
Element
is the most general base class from which all element objects (i.e. objects that represent elements) in a Document inherit. It only has methods and properties common to all kinds of elements. More specific classes inherit from . For example, the HTMLElement interface is the base interface for HTML elements, while the SVGElement interface is the basis for all SVG elements. Most functionality is specified further down the class hierarchy. Languages outside the realm of the Web platform, like XUL through the XULElement interface, also implement .
ElementCreationOptions
Event
The interface represents an event which takes place in the DOM. An event can be triggered by the user action e.g. clicking the mouse button or tapping keyboard, or generated by APIs to represent the progress of an asynchronous task. It can also be triggered programmatically, such as by calling the HTMLElement.click() method of an element, or by defining the event, then sending it to a specified target using EventTarget.dispatchEvent(). There are many types of events, some of which use other interfaces based on the main interface. itself contains the properties and methods which are common to all events. Many DOM elements can be set up to accept (or "listen" for) these events, and execute code in response to process (or "handle") them. Event-handlers are usually connected (or "attached") to various HTML elements (such as <button>, <div>, <span>, etc.) using EventTarget.addEventListener(), and this generally replaces using the old HTML event handler attributes. Further, when properly added, such handlers can also be disconnected if needed using removeEventListener().
EventInit
EventListenerOptions
EventTarget
The interface is implemented by objects that can receive events and may have listeners for them. In other words, any target of events implements the three methods associated with this interface. Element, and its children, as well as Document and Window, are the most common event targets, but other objects can be event targets, too. For example XMLHttpRequest, AudioNode, and AudioContext are also event targets.
GetRootNodeOptions
HTMLCollection
The interface represents a generic collection (array-like object similar to arguments) of elements (in document order) and offers methods and properties for selecting from the list.
MutationObserver
The interface provides the ability to watch for changes being made to the DOM tree. It is designed as a replacement for the older Mutation Events feature, which was part of the DOM3 Events specification.
MutationObserverInit
MutationRecord
A represents an individual DOM mutation. It is the object that is inside the array passed to MutationObserver's callback.
NamedNodeMap
The interface represents a collection of Attr objects. Objects inside a are not in any particular order, unlike NodeList, although they may be accessed by an index as in an array. A object is live and will thus be auto-updated if changes are made to its contents internally or elsewhere.
Node
The DOM interface is an abstract base class upon which many other DOM API objects are based, thus letting those object types to be used similarly and often interchangeably. As an abstract class, there is no such thing as a plain object. All objects that implement functionality are based on one of its subclasses. Most notable are Document, Element, and DocumentFragment. In addition, every kind of DOM node is represented by an interface based on . These include Attr, CharacterData (which Text, Comment, CDATASection and ProcessingInstruction are all based on), and DocumentType. In some cases, a particular feature of the base interface may not apply to one of its child interfaces; in that case, the inheriting node may return null or throw an exception, depending on circumstances. For example, attempting to add children to a node type that cannot have children will throw an exception.
NodeFilter
A interface represents an object used to filter the nodes in a NodeIterator or TreeWalker. A knows nothing about the document or traversing nodes; it only knows how to evaluate a single node against the provided filter.
NodeIterator
The interface represents an iterator over the members of a list of the nodes in a subtree of the DOM. The nodes will be returned in document order.
NodeList
objects are collections of nodes, usually returned by properties such as Node.childNodes and methods such as document.querySelectorAll().
NonDocumentTypeChildNode
NonElementParentNode
ParentNode
ProcessingInstruction
The interface represents a processing instruction; that is, a Node which embeds an instruction targeting a specific application but that can be ignored by any other applications which don't recognize the instruction.
Range
The interface represents a fragment of a document that can contain nodes and parts of text nodes. A range can be created by using the Document.createRange() method. Range objects can also be retrieved by using the getRangeAt() method of the Selection object or the caretRangeFromPoint() method of the Document object. There also is the Range() constructor available.
ShadowRoot
The interface of the Shadow DOM API is the root node of a DOM subtree that is rendered separately from a document's main DOM tree. You can retrieve a reference to an element's shadow root using its Element.shadowRoot property, provided it was created using Element.attachShadow() with the mode option set to open.
ShadowRootInit
Slottable
StaticRange
The DOM interface extends AbstractRange to provide a method to specify a range of content in the DOM whose contents don't update to reflect changes which occur within the DOM tree. This interface offers the same set of properties and methods as AbstractRange. AbstractRange and are not available from web workers.
StaticRangeInit
Text
The interface represents a text node in a DOM tree.
TreeWalker
The object represents the nodes of a document subtree and a position within them. A can be created using the Document.createTreeWalker() method.
XMLDocument
The XMLDocument interface represents an XML document. It inherits from the generic Document and does not add any specific methods or properties to it: nevertheless, several algorithms behave differently with the two types of documents.
XPathEvaluator
The interface allows to compile and evaluate XPath expressions. It is implemented by the Document interface.
XPathEvaluatorBase
XPathExpression
This interface is a compiled XPath expression that can be evaluated on a document or specific node to return information from its DOM tree. This is useful when an expression will be reused in an application, because it is just compiled once and all namespace prefixes which occur within the expression are preresolved. Objects of this type are created by calling XPathEvaluator.createExpression().
XPathNSResolver
The interface permits prefix strings in an XPath expression to be properly bound to namespace URI strings. The XPathEvaluator interface can construct an implementation of from a node, or the interface may be implemented by any application.
XPathResult
The interface represents the results generated by evaluating an XPath expression within the context of a given node. Since XPath expressions can result in a variety of result types, this interface makes it possible to determine and handle the type and value of the result.
XSLTProcessor
Non-standard: This feature is non-standard and is not on a standards track. Do not use it on production sites facing the Web: it will not work for every user. There may also be large incompatibilities between implementations and the behavior may change in the future.Experimental: This is an experimental technologyCheck the Browser compatibility table carefully before using this in production.

Extensions

PropsAbortController on AbortController
PropsAbortSignal on AbortSignal
PropsAbstractRange on AbstractRange
PropsAddEventListenerOptions on AddEventListenerOptions
PropsAttr on Attr
PropsCharacterData on CharacterData
PropsChildNode on ChildNode
PropsCustomEvent on CustomEvent
PropsCustomEventInit on CustomEventInit
PropsDocument on Document
PropsDocumentOrShadowRoot on DocumentOrShadowRoot
PropsDocumentType on DocumentType
PropsDOMImplementation on DOMImplementation
PropsDOMTokenList on DOMTokenList
PropsElement on Element
PropsElementCreationOptions on ElementCreationOptions
PropsEvent on Event
PropsEventInit on EventInit
PropsEventListenerOptions on EventListenerOptions
PropsEventTarget on EventTarget
PropsGetRootNodeOptions on GetRootNodeOptions
PropsHTMLCollection on HTMLCollection
PropsMutationObserver on MutationObserver
PropsMutationObserverInit on MutationObserverInit
PropsMutationRecord on MutationRecord
PropsNamedNodeMap on NamedNodeMap
PropsNode on Node
PropsNodeFilter on NodeFilter
PropsNodeIterator on NodeIterator
PropsNodeList on NodeList
PropsNonDocumentTypeChildNode on NonDocumentTypeChildNode
PropsNonElementParentNode on NonElementParentNode
PropsParentNode on ParentNode
PropsProcessingInstruction on ProcessingInstruction
PropsRange on Range
PropsShadowRoot on ShadowRoot
PropsShadowRootInit on ShadowRootInit
PropsSlottable on Slottable
PropsStaticRangeInit on StaticRangeInit
PropsText on Text
PropsTreeWalker on TreeWalker
PropsXPathEvaluatorBase on XPathEvaluatorBase
PropsXPathExpression on XPathExpression
PropsXPathNSResolver on XPathNSResolver
PropsXPathResult on XPathResult
PropsXSLTProcessor on XSLTProcessor