Interface HTMLDocument
activeElement: Element;
adoptedStyleSheets: CSSStyleSheet[];
alinkColor: string;
all: HTMLAllCollection;
anchors: HTMLCollectionOf<HTMLAnchorElement>;
applets: HTMLCollection;
ATTRIBUTE_NODE: 2;
baseURI: string;
bgColor: string;
body: HTMLElement;
CDATA_SECTION_NODE: 4;
characterSet: string;
charset: string;
childElementCount: number;
childNodes: NodeListOf<ChildNode>;
children: HTMLCollection;
COMMENT_NODE: 8;
compatMode: string;
contentType: string;
cookie: string;
currentScript: HTMLOrSVGScriptElement;
defaultView: Window & typeof globalThis;
designMode: string;
dir: string;
doctype: DocumentType;
DOCUMENT_FRAGMENT_NODE: 11;
DOCUMENT_NODE: 9;
DOCUMENT_POSITION_CONTAINED_BY: 16;
DOCUMENT_POSITION_CONTAINS: 8;
DOCUMENT_POSITION_DISCONNECTED: 1;
DOCUMENT_POSITION_FOLLOWING: 4;
DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC: 32;
DOCUMENT_POSITION_PRECEDING: 2;
DOCUMENT_TYPE_NODE: 10;
documentElement: HTMLElement;
documentURI: string;
domain: string;
ELEMENT_NODE: 1;
embeds: HTMLCollectionOf<HTMLEmbedElement>;
ENTITY_NODE: 6;
ENTITY_REFERENCE_NODE: 5;
fgColor: string;
firstChild: ChildNode;
firstElementChild: Element;
fonts: FontFaceSet;
forms: HTMLCollectionOf<HTMLFormElement>;
fullscreen: boolean;
fullscreenElement: Element;
fullscreenEnabled: boolean;
head: HTMLHeadElement;
hidden: boolean;
images: HTMLCollectionOf<HTMLImageElement>;
implementation: DOMImplementation;
inputEncoding: string;
isConnected: boolean;
lastChild: ChildNode;
lastElementChild: Element;
lastModified: string;
linkColor: string;
links: HTMLCollectionOf<HTMLAnchorElement | HTMLAreaElement>;
nextSibling: ChildNode;
nodeName: string;
nodeType: number;
nodeValue: string;
NOTATION_NODE: 12;
onabort: ((this: GlobalEventHandlers, ev: UIEvent) => any);
onanimationcancel: ((this: GlobalEventHandlers, ev: AnimationEvent) => any);
onanimationend: ((this: GlobalEventHandlers, ev: AnimationEvent) => any);
onanimationiteration: ((this: GlobalEventHandlers, ev: AnimationEvent) => any);
onanimationstart: ((this: GlobalEventHandlers, ev: AnimationEvent) => any);
onauxclick: ((this: GlobalEventHandlers, ev: MouseEvent) => any);
onbeforeinput: ((this: GlobalEventHandlers, ev: InputEvent) => any);
onbeforetoggle: ((this: GlobalEventHandlers, ev: Event) => any);
onbeforexrselect: ((this: GlobalEventHandlers, ev: XRSessionEvent) => any);
onblur: ((this: GlobalEventHandlers, ev: FocusEvent) => any);
oncancel: ((this: GlobalEventHandlers, ev: Event) => any);
oncanplay: ((this: GlobalEventHandlers, ev: Event) => any);
oncanplaythrough: ((this: GlobalEventHandlers, ev: Event) => any);
onchange: ((this: GlobalEventHandlers, ev: Event) => any);
onclick: ((this: GlobalEventHandlers, ev: MouseEvent) => any);
onclose: ((this: GlobalEventHandlers, ev: Event) => any);
oncontextlost: ((this: GlobalEventHandlers, ev: Event) => any);
oncontextmenu: ((this: GlobalEventHandlers, ev: MouseEvent) => any);
oncontextrestored: ((this: GlobalEventHandlers, ev: Event) => any);
oncopy: ((this: GlobalEventHandlers, ev: ClipboardEvent) => any);
oncuechange: ((this: GlobalEventHandlers, ev: Event) => any);
oncut: ((this: GlobalEventHandlers, ev: ClipboardEvent) => any);
ondblclick: ((this: GlobalEventHandlers, ev: MouseEvent) => any);
ondrag: ((this: GlobalEventHandlers, ev: DragEvent) => any);
ondragend: ((this: GlobalEventHandlers, ev: DragEvent) => any);
ondragenter: ((this: GlobalEventHandlers, ev: DragEvent) => any);
ondragleave: ((this: GlobalEventHandlers, ev: DragEvent) => any);
ondragover: ((this: GlobalEventHandlers, ev: DragEvent) => any);
ondragstart: ((this: GlobalEventHandlers, ev: DragEvent) => any);
ondrop: ((this: GlobalEventHandlers, ev: DragEvent) => any);
ondurationchange: ((this: GlobalEventHandlers, ev: Event) => any);
onemptied: ((this: GlobalEventHandlers, ev: Event) => any);
onended: ((this: GlobalEventHandlers, ev: Event) => any);
onerror: OnErrorEventHandlerNonNull;
onfocus: ((this: GlobalEventHandlers, ev: FocusEvent) => any);
onformdata: ((this: GlobalEventHandlers, ev: FormDataEvent) => any);
onfullscreenchange: ((this: Document, ev: Event) => any);
onfullscreenerror: ((this: Document, ev: Event) => any);
ongotpointercapture: ((this: GlobalEventHandlers, ev: PointerEvent) => any);
oninput: ((this: GlobalEventHandlers, ev: Event) => any);
oninvalid: ((this: GlobalEventHandlers, ev: Event) => any);
onkeydown: ((this: GlobalEventHandlers, ev: KeyboardEvent) => any);
onkeypress: ((this: GlobalEventHandlers, ev: KeyboardEvent) => any);
onkeyup: ((this: GlobalEventHandlers, ev: KeyboardEvent) => any);
onload: ((this: GlobalEventHandlers, ev: Event) => any);
onloadeddata: ((this: GlobalEventHandlers, ev: Event) => any);
onloadedmetadata: ((this: GlobalEventHandlers, ev: Event) => any);
onloadstart: ((this: GlobalEventHandlers, ev: Event) => any);
onlostpointercapture: ((this: GlobalEventHandlers, ev: PointerEvent) => any);
onmousedown: ((this: GlobalEventHandlers, ev: MouseEvent) => any);
onmouseenter: ((this: GlobalEventHandlers, ev: MouseEvent) => any);
onmouseleave: ((this: GlobalEventHandlers, ev: MouseEvent) => any);
onmousemove: ((this: GlobalEventHandlers, ev: MouseEvent) => any);
onmouseout: ((this: GlobalEventHandlers, ev: MouseEvent) => any);
onmouseover: ((this: GlobalEventHandlers, ev: MouseEvent) => any);
onmouseup: ((this: GlobalEventHandlers, ev: MouseEvent) => any);
onpaste: ((this: GlobalEventHandlers, ev: ClipboardEvent) => any);
onpause: ((this: GlobalEventHandlers, ev: Event) => any);
onplay: ((this: GlobalEventHandlers, ev: Event) => any);
onplaying: ((this: GlobalEventHandlers, ev: Event) => any);
onpointercancel: ((this: GlobalEventHandlers, ev: PointerEvent) => any);
onpointerdown: ((this: GlobalEventHandlers, ev: PointerEvent) => any);
onpointerenter: ((this: GlobalEventHandlers, ev: PointerEvent) => any);
onpointerleave: ((this: GlobalEventHandlers, ev: PointerEvent) => any);
onpointerlockchange: ((this: Document, ev: Event) => any);
onpointerlockerror: ((this: Document, ev: Event) => any);
onpointermove: ((this: GlobalEventHandlers, ev: PointerEvent) => any);
onpointerout: ((this: GlobalEventHandlers, ev: PointerEvent) => any);
onpointerover: ((this: GlobalEventHandlers, ev: PointerEvent) => any);
onpointerup: ((this: GlobalEventHandlers, ev: PointerEvent) => any);
onprogress: ((this: GlobalEventHandlers, ev: ProgressEvent<EventTarget>) => any);
onratechange: ((this: GlobalEventHandlers, ev: Event) => any);
onreadystatechange: ((this: Document, ev: Event) => any);
onreset: ((this: GlobalEventHandlers, ev: Event) => any);
onresize: ((this: GlobalEventHandlers, ev: UIEvent) => any);
onscroll: ((this: GlobalEventHandlers, ev: Event) => any);
onscrollend: ((this: GlobalEventHandlers, ev: Event) => any);
onsecuritypolicyviolation: ((this: GlobalEventHandlers, ev: SecurityPolicyViolationEvent) => any);
onseeked: ((this: GlobalEventHandlers, ev: Event) => any);
onseeking: ((this: GlobalEventHandlers, ev: Event) => any);
onselect: ((this: GlobalEventHandlers, ev: Event) => any);
onselectionchange: ((this: GlobalEventHandlers, ev: Event) => any);
onselectstart: ((this: GlobalEventHandlers, ev: Event) => any);
onslotchange: ((this: GlobalEventHandlers, ev: Event) => any);
onstalled: ((this: GlobalEventHandlers, ev: Event) => any);
onsubmit: ((this: GlobalEventHandlers, ev: SubmitEvent) => any);
onsuspend: ((this: GlobalEventHandlers, ev: Event) => any);
ontimeupdate: ((this: GlobalEventHandlers, ev: Event) => any);
ontoggle: ((this: GlobalEventHandlers, ev: Event) => any);
ontouchcancel?: ((this: GlobalEventHandlers, ev: TouchEvent) => any);
ontouchend?: ((this: GlobalEventHandlers, ev: TouchEvent) => any);
ontouchmove?: ((this: GlobalEventHandlers, ev: TouchEvent) => any);
ontouchstart?: ((this: GlobalEventHandlers, ev: TouchEvent) => any);
ontransitioncancel: ((this: GlobalEventHandlers, ev: TransitionEvent) => any);
ontransitionend: ((this: GlobalEventHandlers, ev: TransitionEvent) => any);
ontransitionrun: ((this: GlobalEventHandlers, ev: TransitionEvent) => any);
ontransitionstart: ((this: GlobalEventHandlers, ev: TransitionEvent) => any);
onvisibilitychange: ((this: Document, ev: Event) => any);
onvolumechange: ((this: GlobalEventHandlers, ev: Event) => any);
onwaiting: ((this: GlobalEventHandlers, ev: Event) => any);
onwebkitanimationend: ((this: GlobalEventHandlers, ev: Event) => any);
onwebkitanimationiteration: ((this: GlobalEventHandlers, ev: Event) => any);
onwebkitanimationstart: ((this: GlobalEventHandlers, ev: Event) => any);
onwebkittransitionend: ((this: GlobalEventHandlers, ev: Event) => any);
onwheel: ((this: GlobalEventHandlers, ev: WheelEvent) => any);
ownerDocument: null;
parentElement: HTMLElement;
parentNode: ParentNode;
pictureInPictureElement: Element;
pictureInPictureEnabled: boolean;
plugins: HTMLCollectionOf<HTMLEmbedElement>;
pointerLockElement: Element;
previousSibling: ChildNode;
PROCESSING_INSTRUCTION_NODE: 7;
readyState: DocumentReadyState;
referrer: string;
rootElement: SVGSVGElement;
scripts: HTMLCollectionOf<HTMLScriptElement>;
scrollingElement: Element;
styleSheets: StyleSheetList;
TEXT_NODE: 3;
textContent: string;
timeline: DocumentTimeline;
title: string;
URL: string;
visibilityState: DocumentVisibilityState;
vlinkColor: string;
location: Location;
addEventListener<K>(type: K, listener: ((this: HTMLDocument, ev: DocumentEventMap[K]) => any), options?: boolean | AddEventListenerOptions): void;
addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void;
adoptNode<T>(node: T): T;
append(...nodes: (string | Node)[]): void;
appendChild<T>(node: T): T;
captureEvents(): void;
caretRangeFromPoint(x: number, y: number): Range;
clear(): void;
cloneNode(deep?: boolean): Node;
close(): void;
compareDocumentPosition(other: Node): number;
contains(other: Node): boolean;
createAttribute(localName: string): Attr;
createAttributeNS(namespace: string, qualifiedName: string): Attr;
createCDATASection(data: string): CDATASection;
createComment(data: string): Comment;
createDocumentFragment(): DocumentFragment;
createElement<K>(tagName: K, options?: ElementCreationOptions): HTMLElementTagNameMap[K];
createElement<K>(tagName: K, options?: ElementCreationOptions): HTMLElementDeprecatedTagNameMap[K];
createElement(tagName: string, options?: ElementCreationOptions): HTMLElement;
createElementNS(namespaceURI: "http://www.w3.org/1999/xhtml", qualifiedName: string): HTMLElement;
createElementNS<K>(namespaceURI: "http://www.w3.org/2000/svg", qualifiedName: K): SVGElementTagNameMap[K];
createElementNS(namespaceURI: "http://www.w3.org/2000/svg", qualifiedName: string): SVGElement;
createElementNS<K>(namespaceURI: "http://www.w3.org/1998/Math/MathML", qualifiedName: K): MathMLElementTagNameMap[K];
createElementNS(namespaceURI: "http://www.w3.org/1998/Math/MathML", qualifiedName: string): MathMLElement;
createElementNS(namespaceURI: string, qualifiedName: string, options?: ElementCreationOptions): Element;
createElementNS(namespace: string, qualifiedName: string, options?: string | ElementCreationOptions): Element;
createEvent(eventInterface: "AnimationEvent"): AnimationEvent;
createEvent(eventInterface: "AnimationPlaybackEvent"): AnimationPlaybackEvent;
createEvent(eventInterface: "AudioProcessingEvent"): AudioProcessingEvent;
createEvent(eventInterface: "BeforeUnloadEvent"): BeforeUnloadEvent;
createEvent(eventInterface: "BlobEvent"): BlobEvent;
createEvent(eventInterface: "ClipboardEvent"): ClipboardEvent;
createEvent(eventInterface: "CloseEvent"): CloseEvent;
createEvent(eventInterface: "CompositionEvent"): CompositionEvent;
createEvent(eventInterface: "ContentVisibilityAutoStateChangeEvent"): ContentVisibilityAutoStateChangeEvent;
createEvent(eventInterface: "CustomEvent"): CustomEvent<any>;
createEvent(eventInterface: "DeviceMotionEvent"): DeviceMotionEvent;
createEvent(eventInterface: "DeviceOrientationEvent"): DeviceOrientationEvent;
createEvent(eventInterface: "DragEvent"): DragEvent;
createEvent(eventInterface: "ErrorEvent"): ErrorEvent;
createEvent(eventInterface: "Event"): Event;
createEvent(eventInterface: "Events"): Event;
createEvent(eventInterface: "FocusEvent"): FocusEvent;
createEvent(eventInterface: "FontFaceSetLoadEvent"): FontFaceSetLoadEvent;
createEvent(eventInterface: "FormDataEvent"): FormDataEvent;
createEvent(eventInterface: "GamepadEvent"): GamepadEvent;
createEvent(eventInterface: "HashChangeEvent"): HashChangeEvent;
createEvent(eventInterface: "IDBVersionChangeEvent"): IDBVersionChangeEvent;
createEvent(eventInterface: "InputEvent"): InputEvent;
createEvent(eventInterface: "KeyboardEvent"): KeyboardEvent;
createEvent(eventInterface: "MIDIConnectionEvent"): MIDIConnectionEvent;
createEvent(eventInterface: "MIDIMessageEvent"): MIDIMessageEvent;
createEvent(eventInterface: "MediaEncryptedEvent"): MediaEncryptedEvent;
createEvent(eventInterface: "MediaKeyMessageEvent"): MediaKeyMessageEvent;
createEvent(eventInterface: "MediaQueryListEvent"): MediaQueryListEvent;
createEvent(eventInterface: "MediaStreamTrackEvent"): MediaStreamTrackEvent;
createEvent(eventInterface: "MessageEvent"): MessageEvent<any>;
createEvent(eventInterface: "MouseEvent"): MouseEvent;
createEvent(eventInterface: "MouseEvents"): MouseEvent;
createEvent(eventInterface: "MutationEvent"): MutationEvent;
createEvent(eventInterface: "MutationEvents"): MutationEvent;
createEvent(eventInterface: "OfflineAudioCompletionEvent"): OfflineAudioCompletionEvent;
createEvent(eventInterface: "PageTransitionEvent"): PageTransitionEvent;
createEvent(eventInterface: "PaymentMethodChangeEvent"): PaymentMethodChangeEvent;
createEvent(eventInterface: "PaymentRequestUpdateEvent"): PaymentRequestUpdateEvent;
createEvent(eventInterface: "PictureInPictureEvent"): PictureInPictureEvent;
createEvent(eventInterface: "PointerEvent"): PointerEvent;
createEvent(eventInterface: "PopStateEvent"): PopStateEvent;
createEvent(eventInterface: "ProgressEvent"): ProgressEvent<EventTarget>;
createEvent(eventInterface: "PromiseRejectionEvent"): PromiseRejectionEvent;
createEvent(eventInterface: "RTCDTMFToneChangeEvent"): RTCDTMFToneChangeEvent;
createEvent(eventInterface: "RTCDataChannelEvent"): RTCDataChannelEvent;
createEvent(eventInterface: "RTCErrorEvent"): RTCErrorEvent;
createEvent(eventInterface: "RTCPeerConnectionIceErrorEvent"): RTCPeerConnectionIceErrorEvent;
createEvent(eventInterface: "RTCPeerConnectionIceEvent"): RTCPeerConnectionIceEvent;
createEvent(eventInterface: "RTCTrackEvent"): RTCTrackEvent;
createEvent(eventInterface: "SecurityPolicyViolationEvent"): SecurityPolicyViolationEvent;
createEvent(eventInterface: "SpeechSynthesisErrorEvent"): SpeechSynthesisErrorEvent;
createEvent(eventInterface: "SpeechSynthesisEvent"): SpeechSynthesisEvent;
createEvent(eventInterface: "StorageEvent"): StorageEvent;
createEvent(eventInterface: "SubmitEvent"): SubmitEvent;
createEvent(eventInterface: "TextEvent"): TextEvent;
createEvent(eventInterface: "ToggleEvent"): ToggleEvent;
createEvent(eventInterface: "TouchEvent"): TouchEvent;
createEvent(eventInterface: "TrackEvent"): TrackEvent;
createEvent(eventInterface: "TransitionEvent"): TransitionEvent;
createEvent(eventInterface: "UIEvent"): UIEvent;
createEvent(eventInterface: "UIEvents"): UIEvent;
createEvent(eventInterface: "WebGLContextEvent"): WebGLContextEvent;
createEvent(eventInterface: "WheelEvent"): WheelEvent;
createEvent(eventInterface: string): Event;
createExpression(expression: string, resolver?: XPathNSResolver): XPathExpression;
createNodeIterator(root: Node, whatToShow?: number, filter?: NodeFilter): NodeIterator;
createNSResolver(nodeResolver: Node): Node;
createProcessingInstruction(target: string, data: string): ProcessingInstruction;
createRange(): Range;
createTextNode(data: string): Text;
createTreeWalker(root: Node, whatToShow?: number, filter?: NodeFilter): TreeWalker;
dispatchEvent(event: Event): boolean;
elementFromPoint(x: number, y: number): Element;
elementsFromPoint(x: number, y: number): Element[];
evaluate(expression: string, contextNode: Node, resolver?: XPathNSResolver, type?: number, result?: XPathResult): XPathResult;
execCommand(commandId: string, showUI?: boolean, value?: string): boolean;
exitFullscreen(): Promise<void>;
exitPictureInPicture(): Promise<void>;
exitPointerLock(): void;
getAnimations(): Animation[];
getElementById(elementId: string): HTMLElement;
getElementsByClassName(classNames: string): HTMLCollectionOf<Element>;
getElementsByName(elementName: string): NodeListOf<HTMLElement>;
getElementsByTagName<K>(qualifiedName: K): HTMLCollectionOf<HTMLElementTagNameMap[K]>;
getElementsByTagName<K>(qualifiedName: K): HTMLCollectionOf<SVGElementTagNameMap[K]>;
getElementsByTagName<K>(qualifiedName: K): HTMLCollectionOf<MathMLElementTagNameMap[K]>;
getElementsByTagName<K>(qualifiedName: K): HTMLCollectionOf<HTMLElementDeprecatedTagNameMap[K]>;
getElementsByTagName(qualifiedName: string): HTMLCollectionOf<Element>;
getElementsByTagNameNS(namespaceURI: "http://www.w3.org/1999/xhtml", localName: string): HTMLCollectionOf<HTMLElement>;
getElementsByTagNameNS(namespaceURI: "http://www.w3.org/2000/svg", localName: string): HTMLCollectionOf<SVGElement>;
getElementsByTagNameNS(namespaceURI: "http://www.w3.org/1998/Math/MathML", localName: string): HTMLCollectionOf<MathMLElement>;
getElementsByTagNameNS(namespace: string, localName: string): HTMLCollectionOf<Element>;
getRootNode(options?: GetRootNodeOptions): Node;
getSelection(): Selection;
hasChildNodes(): boolean;
hasFocus(): boolean;
hasStorageAccess(): Promise<boolean>;
importNode<T>(node: T, deep?: boolean): T;
insertBefore<T>(node: T, child: Node): T;
isDefaultNamespace(namespace: string): boolean;
isEqualNode(otherNode: Node): boolean;
isSameNode(otherNode: Node): boolean;
lookupNamespaceURI(prefix: string): string;
lookupPrefix(namespace: string): string;
normalize(): void;
open(unused1?: string, unused2?: string): Document;
open(url: string | URL, name: string, features: string): Window;
prepend(...nodes: (string | Node)[]): void;
queryCommandEnabled(commandId: string): boolean;
queryCommandIndeterm(commandId: string): boolean;
queryCommandState(commandId: string): boolean;
queryCommandSupported(commandId: string): boolean;
queryCommandValue(commandId: string): string;
querySelector<K>(selectors: K): HTMLElementTagNameMap[K];
querySelector<K>(selectors: K): SVGElementTagNameMap[K];
querySelector<K>(selectors: K): MathMLElementTagNameMap[K];
querySelector<K>(selectors: K): HTMLElementDeprecatedTagNameMap[K];
querySelector<E>(selectors: string): E;
querySelectorAll<K>(selectors: K): NodeListOf<HTMLElementTagNameMap[K]>;
querySelectorAll<K>(selectors: K): NodeListOf<SVGElementTagNameMap[K]>;
querySelectorAll<K>(selectors: K): NodeListOf<MathMLElementTagNameMap[K]>;
querySelectorAll<K>(selectors: K): NodeListOf<HTMLElementDeprecatedTagNameMap[K]>;
querySelectorAll<E>(selectors: string): NodeListOf<E>;
releaseEvents(): void;
removeChild<T>(child: T): T;
removeEventListener<K>(type: K, listener: ((this: HTMLDocument, ev: DocumentEventMap[K]) => any), options?: boolean | EventListenerOptions): void;
removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void;
replaceChild<T>(node: Node, child: T): T;
replaceChildren(...nodes: (string | Node)[]): void;
requestStorageAccess(): Promise<void>;
startViewTransition(callbackOptions?: UpdateCallback): ViewTransition;
write(...text: string[]): void;
writeln(...text: string[]): void;
}
Index
Properties
Accessors
Methods
Properties
Readonly
activeElement
Returns the deepest element in the document through which or to which key events are being routed. This is, roughly speaking, the focused element in the document.
For the purposes of this API, when a child browsing context is focused, its container is focused in the parent browsing context. For example, if the user moves the focus to a text control in an iframe, the iframe is the element returned by the activeElement API in the iframe's node document.
Similarly, when the focused element is in a different node tree than documentOrShadowRoot, the element returned will be the host that's located in the same node tree as documentOrShadowRoot if documentOrShadowRoot is a shadow-including inclusive ancestor of the focused element, and null if not.
adoptedStyleSheets
alinkColor
Sets or gets the color of all active links in the document.
Readonly
all
Returns a reference to the collection of elements contained by the object.
Readonly
anchors
Retrieves a collection of all a objects that have a name and/or id property. Objects in this collection are in HTML source order.
Readonly
applets
Retrieves a collection of all applet objects in the document.
Readonly
ATTRIBUTE_NODE
Readonly
baseURI
Returns node's node document's document base URL.
bgColor
Deprecated. Sets or retrieves a value that indicates the background color behind the object.
body
Specifies the beginning and end of the document body.
Readonly
CDATA_SECTION_NODE
node is a CDATASection node.
Readonly
characterSet
Returns document's encoding.
Readonly
charset
Gets or sets the character set used to encode the object.
Readonly
childElementCount
Readonly
childNodes
Returns the children.
Readonly
children
Returns the child elements.
Readonly
COMMENT_NODE
node is a Comment node.
Readonly
compatMode
Gets a value that indicates whether standards-compliant mode is switched on for the object.
Readonly
contentType
Returns document's content type.
cookie
Returns the HTTP cookies that apply to the Document. If there are no cookies or cookies can't be applied to this resource, the empty string will be returned.
Can be set, to add a new cookie to the element's set of HTTP cookies.
If the contents are sandboxed into a unique origin (e.g. in an iframe with the sandbox attribute), a "SecurityError" DOMException will be thrown on getting and setting.
Readonly
currentScript
Returns the script element, or the SVG script element, that is currently executing, as long as the element represents a classic script. In the case of reentrant script execution, returns the one that most recently started executing amongst those that have not yet finished executing.
Returns null if the Document is not currently executing a script or SVG script element (e.g., because the running script is an event handler, or a timeout), or if the currently executing script or SVG script element represents a module script.
Readonly
defaultView
Returns the Window object of the active document.
designMode
Sets or gets a value that indicates whether the document can be edited.
dir
Sets or retrieves a value that indicates the reading order of the object.
Readonly
doctype
Gets an object representing the document type declaration associated with the current document.
Readonly
DOCUMENT_FRAGMENT_NODE
node is a DocumentFragment node.
Readonly
DOCUMENT_NODE
node is a document.
Readonly
DOCUMENT_POSITION_CONTAINED_BY
Set when other is a descendant of node.
Readonly
DOCUMENT_POSITION_CONTAINS
Set when other is an ancestor of node.
Readonly
DOCUMENT_POSITION_DISCONNECTED
Set when node and other are not in the same tree.
Readonly
DOCUMENT_POSITION_FOLLOWING
Set when other is following node.
Readonly
DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC
Readonly
DOCUMENT_POSITION_PRECEDING
Set when other is preceding node.
Readonly
DOCUMENT_TYPE_NODE
node is a doctype.
Readonly
documentElement
Gets a reference to the root node of the document.
Readonly
documentURI
Returns document's URL.
domain
Sets or gets the security domain of the document.
Readonly
ELEMENT_NODE
node is an element.
Readonly
embeds
Retrieves a collection of all embed objects in the document.
Readonly
ENTITY_NODE
Readonly
ENTITY_REFERENCE_NODE
fgColor
Sets or gets the foreground (text) color of the document.
Readonly
firstChild
Returns the first child.
Readonly
firstElementChild
Returns the first child that is an element, and null otherwise.
Readonly
fonts
Readonly
forms
Retrieves a collection, in source order, of all form objects in the document.
Readonly
fullscreen
Readonly
fullscreenElement
Returns document's fullscreen element.
Readonly
fullscreenEnabled
Returns true if document has the ability to display elements fullscreen and fullscreen is supported, or false otherwise.
Readonly
head
Returns the head element.
Readonly
hidden
Readonly
images
Retrieves a collection, in source order, of img objects in the document.
Readonly
implementation
Gets the implementation object of the current document.
Readonly
inputEncoding
Returns the character encoding used to create the webpage that is loaded into the document object.
Readonly
isConnected
Returns true if node is connected and false otherwise.
Readonly
lastChild
Returns the last child.
Readonly
lastElementChild
Returns the last child that is an element, and null otherwise.
Readonly
lastModified
Gets the date that the page was last modified, if the page supplies one.
linkColor
Sets or gets the color of the document links.
Readonly
links
Retrieves a collection of all a objects that specify the href property and all area objects in the document.
Readonly
nextSibling
Returns the next sibling.
Readonly
nodeName
Returns a string appropriate for the type of node.
Readonly
nodeType
Returns the type of node.
nodeValue
Readonly
NOTATION_NODE
onabort
Fires when the user aborts the download.
Type declaration
- (this, ev): any
Parameters
- this: GlobalEventHandlers
- ev: UIEvent
The event.
Returns any
onanimationcancel
onanimationend
onanimationiteration
onanimationstart
onauxclick
onbeforeinput
onbeforetoggle
onbeforexrselect
An XRSessionEvent of type beforexrselect is dispatched on the DOM overlay element before generating a WebXR selectstart input event if the -Z axis of the input source's targetRaySpace intersects the DOM overlay element at the time the input device's primary action is triggered.
onblur
Fires when the object loses the input focus.
Type declaration
- (this, ev): any
Parameters
- this: GlobalEventHandlers
- ev: FocusEvent
The focus event.
Returns any
oncancel
oncanplay
Occurs when playback is possible, but would require further buffering.
Type declaration
- (this, ev): any
Parameters
- this: GlobalEventHandlers
- ev: Event
The event.
Returns any
oncanplaythrough
onchange
Fires when the contents of the object or selection have changed.
Type declaration
- (this, ev): any
Parameters
- this: GlobalEventHandlers
- ev: Event
The event.
Returns any
onclick
Fires when the user clicks the left mouse button on the object
Type declaration
- (this, ev): any
Parameters
- this: GlobalEventHandlers
- ev: MouseEvent
The mouse event.
Returns any
onclose
oncontextlost
oncontextmenu
Fires when the user clicks the right mouse button in the client area, opening the context menu.
Type declaration
Parameters
- this: GlobalEventHandlers
- ev: MouseEvent
The mouse event.
Returns any
oncontextrestored
oncopy
oncuechange
oncut
ondblclick
Fires when the user double-clicks the object.
Type declaration
- (this, ev): any
Parameters
- this: GlobalEventHandlers
- ev: MouseEvent
The mouse event.
Returns any
ondrag
Fires on the source object continuously during a drag operation.
Type declaration
- (this, ev): any
Parameters
- this: GlobalEventHandlers
- ev: DragEvent
The event.
Returns any
ondragend
Fires on the source object when the user releases the mouse at the close of a drag operation.
Type declaration
- (this, ev): any
Parameters
- this: GlobalEventHandlers
- ev: DragEvent
The event.
Returns any
ondragenter
Fires on the target element when the user drags the object to a valid drop target.
Type declaration
- (this, ev): any
Parameters
- this: GlobalEventHandlers
- ev: DragEvent
The drag event.
Returns any
ondragleave
Fires on the target object when the user moves the mouse out of a valid drop target during a drag operation.
Type declaration
- (this, ev): any
Parameters
- this: GlobalEventHandlers
- ev: DragEvent
The drag event.
Returns any
ondragover
Fires on the target element continuously while the user drags the object over a valid drop target.
Type declaration
- (this, ev): any
Parameters
- this: GlobalEventHandlers
- ev: DragEvent
The event.
Returns any
ondragstart
Fires on the source object when the user starts to drag a text selection or selected object.
Type declaration
- (this, ev): any
Parameters
- this: GlobalEventHandlers
- ev: DragEvent
The event.
Returns any
ondrop
ondurationchange
Occurs when the duration attribute is updated.
Type declaration
- (this, ev): any
Parameters
- this: GlobalEventHandlers
- ev: Event
The event.
Returns any
onemptied
Occurs when the media element is reset to its initial state.
Type declaration
- (this, ev): any
Parameters
- this: GlobalEventHandlers
- ev: Event
The event.
Returns any
onended
Occurs when the end of playback is reached.
Type declaration
- (this, ev): any
Parameters
- this: GlobalEventHandlers
- ev: Event
The event
Returns any
onerror
Fires when an error occurs during object loading.
onfocus
Fires when the object receives focus.
Type declaration
- (this, ev): any
Parameters
- this: GlobalEventHandlers
- ev: FocusEvent
The event.
Returns any
onformdata
onfullscreenchange
onfullscreenerror
ongotpointercapture
oninput
oninvalid
onkeydown
Fires when the user presses a key.
Type declaration
- (this, ev): any
Parameters
- this: GlobalEventHandlers
- ev: KeyboardEvent
The keyboard event
Returns any
onkeypress
Fires when the user presses an alphanumeric key.
Type declaration
- (this, ev): any
Parameters
- this: GlobalEventHandlers
- ev: KeyboardEvent
The event.
Returns any
onkeyup
Fires when the user releases a key.
Type declaration
- (this, ev): any
Parameters
- this: GlobalEventHandlers
- ev: KeyboardEvent
The keyboard event
Returns any
onload
Fires immediately after the browser loads the object.
Type declaration
- (this, ev): any
Parameters
- this: GlobalEventHandlers
- ev: Event
The event.
Returns any
onloadeddata
Occurs when media data is loaded at the current playback position.
Type declaration
- (this, ev): any
Parameters
- this: GlobalEventHandlers
- ev: Event
The event.
Returns any
onloadedmetadata
Occurs when the duration and dimensions of the media have been determined.
Type declaration
- (this, ev): any
Parameters
- this: GlobalEventHandlers
- ev: Event
The event.
Returns any
onloadstart
Occurs when Internet Explorer begins looking for media data.
Type declaration
- (this, ev): any
Parameters
- this: GlobalEventHandlers
- ev: Event
The event.
Returns any
onlostpointercapture
onmousedown
Fires when the user clicks the object with either mouse button.
Type declaration
- (this, ev): any
Parameters
- this: GlobalEventHandlers
- ev: MouseEvent
The mouse event.
Returns any
onmouseenter
onmouseleave
onmousemove
Fires when the user moves the mouse over the object.
Type declaration
- (this, ev): any
Parameters
- this: GlobalEventHandlers
- ev: MouseEvent
The mouse event.
Returns any
onmouseout
Fires when the user moves the mouse pointer outside the boundaries of the object.
Type declaration
- (this, ev): any
Parameters
- this: GlobalEventHandlers
- ev: MouseEvent
The mouse event.
Returns any
onmouseover
Fires when the user moves the mouse pointer into the object.
Type declaration
- (this, ev): any
Parameters
- this: GlobalEventHandlers
- ev: MouseEvent
The mouse event.
Returns any
onmouseup
Fires when the user releases a mouse button while the mouse is over the object.
Type declaration
- (this, ev): any
Parameters
- this: GlobalEventHandlers
- ev: MouseEvent
The mouse event.
Returns any
onpaste
onpause
Occurs when playback is paused.
Type declaration
- (this, ev): any
Parameters
- this: GlobalEventHandlers
- ev: Event
The event.
Returns any
onplay
Occurs when the play method is requested.
Type declaration
- (this, ev): any
Parameters
- this: GlobalEventHandlers
- ev: Event
The event.
Returns any
onplaying
Occurs when the audio or video has started playing.
Type declaration
- (this, ev): any
Parameters
- this: GlobalEventHandlers
- ev: Event
The event.
Returns any
onpointercancel
onpointerdown
onpointerenter
onpointerleave
onpointerlockchange
onpointerlockerror
onpointermove
onpointerout
onpointerover
onpointerup
onprogress
Occurs to indicate progress while downloading media data.
Type declaration
- (this, ev): any
Parameters
- this: GlobalEventHandlers
- ev: ProgressEvent<EventTarget>
The event.
Returns any
onratechange
Occurs when the playback rate is increased or decreased.
Type declaration
- (this, ev): any
Parameters
- this: GlobalEventHandlers
- ev: Event
The event.
Returns any
onreadystatechange
Fires when the state of the object has changed.
onreset
Fires when the user resets a form.
Type declaration
- (this, ev): any
Parameters
- this: GlobalEventHandlers
- ev: Event
The event.
Returns any
onresize
onscroll
Fires when the user repositions the scroll box in the scroll bar on the object.
Type declaration
- (this, ev): any
Parameters
- this: GlobalEventHandlers
- ev: Event
The event.
Returns any
onscrollend
onsecuritypolicyviolation
onseeked
Occurs when the seek operation ends.
Type declaration
- (this, ev): any
Parameters
- this: GlobalEventHandlers
- ev: Event
The event.
Returns any
onseeking
Occurs when the current playback position is moved.
Type declaration
- (this, ev): any
Parameters
- this: GlobalEventHandlers
- ev: Event
The event.
Returns any
onselect
Fires when the current selection changes.
Type declaration
- (this, ev): any
Parameters
- this: GlobalEventHandlers
- ev: Event
The event.
Returns any
onselectionchange
onselectstart
onslotchange
onstalled
Occurs when the download has stopped.
Type declaration
- (this, ev): any
Parameters
- this: GlobalEventHandlers
- ev: Event
The event.
Returns any
onsubmit
onsuspend
Occurs if the load operation has been intentionally halted.
Type declaration
- (this, ev): any
Parameters
- this: GlobalEventHandlers
- ev: Event
The event.
Returns any
ontimeupdate
Occurs to indicate the current playback position.
Type declaration
- (this, ev): any
Parameters
- this: GlobalEventHandlers
- ev: Event
The event.
Returns any
ontoggle
Optional
ontouchcancel
Optional
ontouchend
Optional
ontouchmove
Optional
ontouchstart
ontransitioncancel
ontransitionend
ontransitionrun
ontransitionstart
onvisibilitychange
onvolumechange
Occurs when the volume is changed, or playback is muted or unmuted.
Type declaration
- (this, ev): any
Parameters
- this: GlobalEventHandlers
- ev: Event
The event.
Returns any
onwaiting
Occurs when playback stops because the next frame of a video resource is not available.
Type declaration
- (this, ev): any
Parameters
- this: GlobalEventHandlers
- ev: Event
The event.
Returns any
onwebkitanimationend
onwebkitanimationiteration
onwebkitanimationstart
onwebkittransitionend
onwheel
Readonly
ownerDocument
Returns the node document. Returns null for documents.
Readonly
parentElement
Returns the parent element.
Readonly
parentNode
Returns the parent.
Readonly
pictureInPictureElement
Readonly
pictureInPictureEnabled
Readonly
plugins
Return an HTMLCollection of the embed elements in the Document.
Readonly
pointerLockElement
Readonly
previousSibling
Returns the previous sibling.
Readonly
PROCESSING_INSTRUCTION_NODE
node is a ProcessingInstruction node.
Readonly
readyState
Retrieves a value that indicates the current state of the object.
Readonly
referrer
Gets the URL of the location that referred the user to the current page.
Readonly
rootElement
Readonly
scripts
Retrieves a collection of all script objects in the document.
Readonly
scrollingElement
Readonly
styleSheets
Retrieves a collection of styleSheet objects representing the style sheets that correspond to each instance of a link or style object in the document.
Readonly
TEXT_NODE
node is a Text node.
textContent
Readonly
timeline
title
Contains the title of the document.
Readonly
URL
Sets or gets the URL for the current document.
Readonly
visibilityState
vlinkColor
Sets or gets the color of the links that the user has visited.
Accessors
location
Methods
addEventListener
- add
Event <K>(type, listener, options?): voidListener Appends an event listener for events whose type attribute value is type. The callback argument sets the callback that will be invoked when the event is dispatched.
The options argument sets listener-specific options. For compatibility this can be a boolean, in which case the method behaves exactly as if the value was specified as options's capture.
When set to true, options's capture prevents callback from being invoked when the event's eventPhase attribute value is BUBBLING_PHASE. When false (or not present), callback will not be invoked when event's eventPhase attribute value is CAPTURING_PHASE. Either way, callback will be invoked if event's eventPhase attribute value is AT_TARGET.
When set to true, options's passive indicates that the callback will not cancel the event by invoking preventDefault(). This is used to enable performance optimizations described in § 2.8 Observing event listeners.
When set to true, options's once indicates that the callback will only be invoked once after which the event listener will be removed.
If an AbortSignal is passed for options's signal, then the event listener will be removed when signal is aborted.
The event listener is appended to target's event listener list and is not appended if it has the same type, callback, and capture.
Type Parameters
- K extends keyof DocumentEventMap
Parameters
- type: K
- listener: ((this: HTMLDocument, ev: DocumentEventMap[K]) => any)
- (this, ev): any
Parameters
- this: HTMLDocument
- ev: DocumentEventMap[K]
Returns any
Optional
options: boolean | AddEventListenerOptions
Returns void
- add
Event (type, listener, options?): voidListener Appends an event listener for events whose type attribute value is type. The callback argument sets the callback that will be invoked when the event is dispatched.
The options argument sets listener-specific options. For compatibility this can be a boolean, in which case the method behaves exactly as if the value was specified as options's capture.
When set to true, options's capture prevents callback from being invoked when the event's eventPhase attribute value is BUBBLING_PHASE. When false (or not present), callback will not be invoked when event's eventPhase attribute value is CAPTURING_PHASE. Either way, callback will be invoked if event's eventPhase attribute value is AT_TARGET.
When set to true, options's passive indicates that the callback will not cancel the event by invoking preventDefault(). This is used to enable performance optimizations described in § 2.8 Observing event listeners.
When set to true, options's once indicates that the callback will only be invoked once after which the event listener will be removed.
If an AbortSignal is passed for options's signal, then the event listener will be removed when signal is aborted.
The event listener is appended to target's event listener list and is not appended if it has the same type, callback, and capture.
Parameters
- type: string
- listener: EventListenerOrEventListenerObject
Optional
options: boolean | AddEventListenerOptions
Returns void
adoptNode
append
- append(...nodes): void
Inserts nodes after the last child of node, while replacing strings in nodes with equivalent Text nodes.
Throws a "HierarchyRequestError" DOMException if the constraints of the node tree are violated.
Parameters
Rest
...nodes: (string | Node)[]
Returns void
appendChild
captureEvents
caretRangeFromPoint
clear
cloneNode
close
compareDocumentPosition
- compare
Document (other): numberPosition Returns a bitmask indicating the position of other relative to node.
Parameters
- other: Node
Returns number
contains
- contains(other): boolean
Returns true if other is an inclusive descendant of node, and false otherwise.
Parameters
- other: Node
Returns boolean
createAttribute
createAttributeNS
createCDATASection
- createCDATASection(data): CDATASection
Returns a CDATASection node whose data is data.
Parameters
- data: string
Returns CDATASection
createComment
createDocumentFragment
- create
Document (): DocumentFragmentFragment Creates a new document.
Returns DocumentFragment
createElement
- create
Element <K>(tagName, options?): HTMLElementTagNameMap[K] Creates an instance of the element for the specified tag.
Type Parameters
- K extends keyof HTMLElementTagNameMap
Parameters
- tagName: K
The name of an element.
Optional
options: ElementCreationOptions
Returns HTMLElementTagNameMap[K]
- create
Element <K>(tagName, options?): HTMLElementDeprecatedTagNameMap[K] Type Parameters
- K extends keyof HTMLElementDeprecatedTagNameMap
Parameters
- tagName: K
Optional
options: ElementCreationOptions
Returns HTMLElementDeprecatedTagNameMap[K]
- create
Element (tagName, options?): HTMLElement Parameters
- tagName: string
Optional
options: ElementCreationOptions
Returns HTMLElement
createElementNS
- create
ElementNS (namespaceURI, qualifiedName): HTMLElement Returns an element with namespace namespace. Its namespace prefix will be everything before ":" (U+003E) in qualifiedName or null. Its local name will be everything after ":" (U+003E) in qualifiedName or qualifiedName.
If localName does not match the Name production an "InvalidCharacterError" DOMException will be thrown.
If one of the following conditions is true a "NamespaceError" DOMException will be thrown:
localName does not match the QName production. Namespace prefix is not null and namespace is the empty string. Namespace prefix is "xml" and namespace is not the XML namespace. qualifiedName or namespace prefix is "xmlns" and namespace is not the XMLNS namespace. namespace is the XMLNS namespace and neither qualifiedName nor namespace prefix is "xmlns".
When supplied, options's is can be used to create a customized built-in element.
Parameters
- namespaceURI: "http://www.w3.org/1999/xhtml"
- qualifiedName: string
Returns HTMLElement
- create
ElementNS <K>(namespaceURI, qualifiedName): SVGElementTagNameMap[K] Type Parameters
- K extends keyof SVGElementTagNameMap
Parameters
- namespaceURI: "http://www.w3.org/2000/svg"
- qualifiedName: K
Returns SVGElementTagNameMap[K]
- create
ElementNS (namespaceURI, qualifiedName): SVGElement Parameters
- namespaceURI: "http://www.w3.org/2000/svg"
- qualifiedName: string
Returns SVGElement
- create
ElementNS <K>(namespaceURI, qualifiedName): MathMLElementTagNameMap[K] Type Parameters
- K extends keyof MathMLElementTagNameMap
Parameters
- namespaceURI: "http://www.w3.org/1998/Math/MathML"
- qualifiedName: K
Returns MathMLElementTagNameMap[K]
- create
ElementNS (namespaceURI, qualifiedName): MathMLElement Parameters
- namespaceURI: "http://www.w3.org/1998/Math/MathML"
- qualifiedName: string
Returns MathMLElement
- create
ElementNS (namespaceURI, qualifiedName, options?): Element Parameters
- namespaceURI: string
- qualifiedName: string
Optional
options: ElementCreationOptions
Returns Element
- create
ElementNS (namespace, qualifiedName, options?): Element Parameters
- namespace: string
- qualifiedName: string
Optional
options: string | ElementCreationOptions
Returns Element
createEvent
- create
Event (eventInterface): AnimationEvent Parameters
- eventInterface: "AnimationEvent"
Returns AnimationEvent
- create
Event (eventInterface): AnimationPlaybackEvent Parameters
- eventInterface: "AnimationPlaybackEvent"
Returns AnimationPlaybackEvent
- create
Event (eventInterface): AudioProcessingEvent Parameters
- eventInterface: "AudioProcessingEvent"
Returns AudioProcessingEvent
- create
Event (eventInterface): BeforeUnloadEvent Parameters
- eventInterface: "BeforeUnloadEvent"
Returns BeforeUnloadEvent
- create
Event (eventInterface): BlobEvent Parameters
- eventInterface: "BlobEvent"
Returns BlobEvent
- create
Event (eventInterface): ClipboardEvent Parameters
- eventInterface: "ClipboardEvent"
Returns ClipboardEvent
- create
Event (eventInterface): CloseEvent Parameters
- eventInterface: "CloseEvent"
Returns CloseEvent
- create
Event (eventInterface): CompositionEvent Parameters
- eventInterface: "CompositionEvent"
Returns CompositionEvent
- create
Event (eventInterface): ContentVisibilityAutoStateChangeEvent Parameters
- eventInterface: "ContentVisibilityAutoStateChangeEvent"
Returns ContentVisibilityAutoStateChangeEvent
- create
Event (eventInterface): CustomEvent<any> Parameters
- eventInterface: "CustomEvent"
Returns CustomEvent<any>
- create
Event (eventInterface): DeviceMotionEvent Parameters
- eventInterface: "DeviceMotionEvent"
Returns DeviceMotionEvent
- create
Event (eventInterface): DeviceOrientationEvent Parameters
- eventInterface: "DeviceOrientationEvent"
Returns DeviceOrientationEvent
- create
Event (eventInterface): DragEvent Parameters
- eventInterface: "DragEvent"
Returns DragEvent
- create
Event (eventInterface): ErrorEvent Parameters
- eventInterface: "ErrorEvent"
Returns ErrorEvent
- create
Event (eventInterface): Event Parameters
- eventInterface: "Event"
Returns Event
- create
Event (eventInterface): Event Parameters
- eventInterface: "Events"
Returns Event
- create
Event (eventInterface): FocusEvent Parameters
- eventInterface: "FocusEvent"
Returns FocusEvent
- create
Event (eventInterface): FontFaceSetLoadEvent Parameters
- eventInterface: "FontFaceSetLoadEvent"
Returns FontFaceSetLoadEvent
- create
Event (eventInterface): FormDataEvent Parameters
- eventInterface: "FormDataEvent"
Returns FormDataEvent
- create
Event (eventInterface): GamepadEvent Parameters
- eventInterface: "GamepadEvent"
Returns GamepadEvent
- create
Event (eventInterface): HashChangeEvent Parameters
- eventInterface: "HashChangeEvent"
Returns HashChangeEvent
- create
Event (eventInterface): IDBVersionChangeEvent Parameters
- eventInterface: "IDBVersionChangeEvent"
Returns IDBVersionChangeEvent
- create
Event (eventInterface): InputEvent Parameters
- eventInterface: "InputEvent"
Returns InputEvent
- create
Event (eventInterface): KeyboardEvent Parameters
- eventInterface: "KeyboardEvent"
Returns KeyboardEvent
- create
Event (eventInterface): MIDIConnectionEvent Parameters
- eventInterface: "MIDIConnectionEvent"
Returns MIDIConnectionEvent
- create
Event (eventInterface): MIDIMessageEvent Parameters
- eventInterface: "MIDIMessageEvent"
Returns MIDIMessageEvent
- create
Event (eventInterface): MediaEncryptedEvent Parameters
- eventInterface: "MediaEncryptedEvent"
Returns MediaEncryptedEvent
- create
Event (eventInterface): MediaKeyMessageEvent Parameters
- eventInterface: "MediaKeyMessageEvent"
Returns MediaKeyMessageEvent
- create
Event (eventInterface): MediaQueryListEvent Parameters
- eventInterface: "MediaQueryListEvent"
Returns MediaQueryListEvent
- create
Event (eventInterface): MediaStreamTrackEvent Parameters
- eventInterface: "MediaStreamTrackEvent"
Returns MediaStreamTrackEvent
- create
Event (eventInterface): MessageEvent<any> Parameters
- eventInterface: "MessageEvent"
Returns MessageEvent<any>
- create
Event (eventInterface): MouseEvent Parameters
- eventInterface: "MouseEvent"
Returns MouseEvent
- create
Event (eventInterface): MouseEvent Parameters
- eventInterface: "MouseEvents"
Returns MouseEvent
- create
Event (eventInterface): MutationEvent Parameters
- eventInterface: "MutationEvent"
Returns MutationEvent
- create
Event (eventInterface): MutationEvent Parameters
- eventInterface: "MutationEvents"
Returns MutationEvent
- create
Event (eventInterface): OfflineAudioCompletionEvent Parameters
- eventInterface: "OfflineAudioCompletionEvent"
Returns OfflineAudioCompletionEvent
- create
Event (eventInterface): PageTransitionEvent Parameters
- eventInterface: "PageTransitionEvent"
Returns PageTransitionEvent
- create
Event (eventInterface): PaymentMethodChangeEvent Parameters
- eventInterface: "PaymentMethodChangeEvent"
Returns PaymentMethodChangeEvent
- create
Event (eventInterface): PaymentRequestUpdateEvent Parameters
- eventInterface: "PaymentRequestUpdateEvent"
Returns PaymentRequestUpdateEvent
- create
Event (eventInterface): PictureInPictureEvent Parameters
- eventInterface: "PictureInPictureEvent"
Returns PictureInPictureEvent
- create
Event (eventInterface): PointerEvent Parameters
- eventInterface: "PointerEvent"
Returns PointerEvent
- create
Event (eventInterface): PopStateEvent Parameters
- eventInterface: "PopStateEvent"
Returns PopStateEvent
- create
Event (eventInterface): ProgressEvent<EventTarget> Parameters
- eventInterface: "ProgressEvent"
Returns ProgressEvent<EventTarget>
- create
Event (eventInterface): PromiseRejectionEvent Parameters
- eventInterface: "PromiseRejectionEvent"
Returns PromiseRejectionEvent
- create
Event (eventInterface): RTCDTMFToneChangeEvent Parameters
- eventInterface: "RTCDTMFToneChangeEvent"
Returns RTCDTMFToneChangeEvent
- create
Event (eventInterface): RTCDataChannelEvent Parameters
- eventInterface: "RTCDataChannelEvent"
Returns RTCDataChannelEvent
- create
Event (eventInterface): RTCErrorEvent Parameters
- eventInterface: "RTCErrorEvent"
Returns RTCErrorEvent
- create
Event (eventInterface): RTCPeerConnectionIceErrorEvent Parameters
- eventInterface: "RTCPeerConnectionIceErrorEvent"
Returns RTCPeerConnectionIceErrorEvent
- create
Event (eventInterface): RTCPeerConnectionIceEvent Parameters
- eventInterface: "RTCPeerConnectionIceEvent"
Returns RTCPeerConnectionIceEvent
- create
Event (eventInterface): RTCTrackEvent Parameters
- eventInterface: "RTCTrackEvent"
Returns RTCTrackEvent
- create
Event (eventInterface): SecurityPolicyViolationEvent Parameters
- eventInterface: "SecurityPolicyViolationEvent"
Returns SecurityPolicyViolationEvent
- create
Event (eventInterface): SpeechSynthesisErrorEvent Parameters
- eventInterface: "SpeechSynthesisErrorEvent"
Returns SpeechSynthesisErrorEvent
- create
Event (eventInterface): SpeechSynthesisEvent Parameters
- eventInterface: "SpeechSynthesisEvent"
Returns SpeechSynthesisEvent
- create
Event (eventInterface): StorageEvent Parameters
- eventInterface: "StorageEvent"
Returns StorageEvent
- create
Event (eventInterface): SubmitEvent Parameters
- eventInterface: "SubmitEvent"
Returns SubmitEvent
- create
Event (eventInterface): TextEvent Parameters
- eventInterface: "TextEvent"
Returns TextEvent
- create
Event (eventInterface): ToggleEvent Parameters
- eventInterface: "ToggleEvent"
Returns ToggleEvent
- create
Event (eventInterface): TouchEvent Parameters
- eventInterface: "TouchEvent"
Returns TouchEvent
- create
Event (eventInterface): TrackEvent Parameters
- eventInterface: "TrackEvent"
Returns TrackEvent
- create
Event (eventInterface): TransitionEvent Parameters
- eventInterface: "TransitionEvent"
Returns TransitionEvent
- create
Event (eventInterface): UIEvent Parameters
- eventInterface: "UIEvent"
Returns UIEvent
- create
Event (eventInterface): UIEvent Parameters
- eventInterface: "UIEvents"
Returns UIEvent
- create
Event (eventInterface): WebGLContextEvent Parameters
- eventInterface: "WebGLContextEvent"
Returns WebGLContextEvent
- create
Event (eventInterface): WheelEvent Parameters
- eventInterface: "WheelEvent"
Returns WheelEvent
- create
Event (eventInterface): Event Parameters
- eventInterface: string
Returns Event
createExpression
- create
Expression (expression, resolver?): XPathExpression Parameters
- expression: string
Optional
resolver: XPathNSResolver
Returns XPathExpression
createNodeIterator
- create
Node (root, whatToShow?, filter?): NodeIteratorIterator Creates a NodeIterator object that you can use to traverse filtered lists of nodes or elements in a document.
Parameters
- root: Node
The root element or node to start traversing on.
Optional
whatToShow: numberThe type of nodes or elements to appear in the node list
Optional
filter: NodeFilterA custom NodeFilter function to use. For more information, see filter. Use null for no filter.
Returns NodeIterator
- root: Node
createNSResolver
createProcessingInstruction
- create
Processing (target, data): ProcessingInstructionInstruction Returns a ProcessingInstruction node whose target is target and data is data. If target does not match the Name production an "InvalidCharacterError" DOMException will be thrown. If data contains "?>" an "InvalidCharacterError" DOMException will be thrown.
Parameters
- target: string
- data: string
Returns ProcessingInstruction
createRange
createTextNode
createTreeWalker
- create
Tree (root, whatToShow?, filter?): TreeWalkerWalker Creates a TreeWalker object that you can use to traverse filtered lists of nodes or elements in a document.
Parameters
- root: Node
The root element or node to start traversing on.
Optional
whatToShow: numberThe type of nodes or elements to appear in the node list. For more information, see whatToShow.
Optional
filter: NodeFilterA custom NodeFilter function to use.
Returns TreeWalker
- root: Node
dispatchEvent
- dispatch
Event (event): boolean Dispatches a synthetic event event to target and returns true if either event's cancelable attribute value is false or its preventDefault() method was not invoked, and false otherwise.
Parameters
- event: Event
Returns boolean
elementFromPoint
elementsFromPoint
evaluate
- evaluate(expression, contextNode, resolver?, type?, result?): XPathResult
Parameters
- expression: string
- contextNode: Node
Optional
resolver: XPathNSResolverOptional
type: numberOptional
result: XPathResult
Returns XPathResult
execCommand
- exec
Command (commandId, showUI?, value?): boolean Executes a command on the current document, current selection, or the given range.
Parameters
- commandId: string
String that specifies the command to execute. This command can be any of the command identifiers that can be executed in script.
Optional
showUI: booleanDisplay the user interface, defaults to false.
Optional
value: stringValue to assign.
Returns boolean
- commandId: string
exitFullscreen
exitPictureInPicture
exitPointerLock
getAnimations
getElementById
- get
Element (elementId): HTMLElementBy Id Returns a reference to the first object with the specified value of the ID attribute.
Parameters
- elementId: string
String that specifies the ID value.
Returns HTMLElement
- elementId: string
getElementsByClassName
- get
Elements (classNames): HTMLCollectionOf<Element>By Class Name Returns a HTMLCollection of the elements in the object on which the method was invoked (a document or an element) that have all the classes given by classNames. The classNames argument is interpreted as a space-separated list of classes.
Parameters
- classNames: string
Returns HTMLCollectionOf<Element>
getElementsByName
- get
Elements (elementName): NodeListOf<HTMLElement>By Name Gets a collection of objects based on the value of the NAME or ID attribute.
Parameters
- elementName: string
Gets a collection of objects based on the value of the NAME or ID attribute.
Returns NodeListOf<HTMLElement>
- elementName: string
getElementsByTagName
- get
Elements <K>(qualifiedName): HTMLCollectionOf<HTMLElementTagNameMap[K]>By Tag Name Retrieves a collection of objects based on the specified element name.
Type Parameters
- K extends keyof HTMLElementTagNameMap
Parameters
- qualifiedName: K
Returns HTMLCollectionOf<HTMLElementTagNameMap[K]>
- get
Elements <K>(qualifiedName): HTMLCollectionOf<SVGElementTagNameMap[K]>By Tag Name Type Parameters
- K extends keyof SVGElementTagNameMap
Parameters
- qualifiedName: K
Returns HTMLCollectionOf<SVGElementTagNameMap[K]>
- get
Elements <K>(qualifiedName): HTMLCollectionOf<MathMLElementTagNameMap[K]>By Tag Name Type Parameters
- K extends keyof MathMLElementTagNameMap
Parameters
- qualifiedName: K
Returns HTMLCollectionOf<MathMLElementTagNameMap[K]>
- get
Elements <K>(qualifiedName): HTMLCollectionOf<HTMLElementDeprecatedTagNameMap[K]>By Tag Name Type Parameters
- K extends keyof HTMLElementDeprecatedTagNameMap
Parameters
- qualifiedName: K
Returns HTMLCollectionOf<HTMLElementDeprecatedTagNameMap[K]>
- get
Elements (qualifiedName): HTMLCollectionOf<Element>By Tag Name Parameters
- qualifiedName: string
Returns HTMLCollectionOf<Element>
getElementsByTagNameNS
- get
Elements (namespaceURI, localName): HTMLCollectionOf<HTMLElement>By Tag NameNS If namespace and localName are "*" returns a HTMLCollection of all descendant elements.
If only namespace is "*" returns a HTMLCollection of all descendant elements whose local name is localName.
If only localName is "*" returns a HTMLCollection of all descendant elements whose namespace is namespace.
Otherwise, returns a HTMLCollection of all descendant elements whose namespace is namespace and local name is localName.
Parameters
- namespaceURI: "http://www.w3.org/1999/xhtml"
- localName: string
Returns HTMLCollectionOf<HTMLElement>
- get
Elements (namespaceURI, localName): HTMLCollectionOf<SVGElement>By Tag NameNS Parameters
- namespaceURI: "http://www.w3.org/2000/svg"
- localName: string
Returns HTMLCollectionOf<SVGElement>
- get
Elements (namespaceURI, localName): HTMLCollectionOf<MathMLElement>By Tag NameNS Parameters
- namespaceURI: "http://www.w3.org/1998/Math/MathML"
- localName: string
Returns HTMLCollectionOf<MathMLElement>
- get
Elements (namespace, localName): HTMLCollectionOf<Element>By Tag NameNS Parameters
- namespace: string
- localName: string
Returns HTMLCollectionOf<Element>
getRootNode
- get
Root (options?): NodeNode Returns node's root.
Parameters
Optional
options: GetRootNodeOptions
Returns Node
getSelection
hasChildNodes
hasFocus
hasStorageAccess
importNode
insertBefore
isDefaultNamespace
isEqualNode
- is
Equal (otherNode): booleanNode Returns whether node and otherNode have the same properties.
Parameters
- otherNode: Node
Returns boolean
isSameNode
- is
Same (otherNode): booleanNode Parameters
- otherNode: Node
Returns boolean
lookupNamespaceURI
lookupPrefix
normalize
open
- open(unused1?, unused2?): Document
Opens a new window and loads a document specified by a given URL. Also, opens a new window that uses the url parameter and the name parameter to collect the output of the write method and the writeln method.
Parameters
Optional
unused1: stringOptional
unused2: string
Returns Document
- open(url, name, features): Window
Parameters
- url: string | URL
- name: string
- features: string
Returns Window
prepend
- prepend(...nodes): void
Inserts nodes before the first child of node, while replacing strings in nodes with equivalent Text nodes.
Throws a "HierarchyRequestError" DOMException if the constraints of the node tree are violated.
Parameters
Rest
...nodes: (string | Node)[]
Returns void
queryCommandEnabled
queryCommandIndeterm
queryCommandState
queryCommandSupported
queryCommandValue
querySelector
- query
Selector <K>(selectors): HTMLElementTagNameMap[K] Returns the first element that is a descendant of node that matches selectors.
Type Parameters
- K extends keyof HTMLElementTagNameMap
Parameters
- selectors: K
Returns HTMLElementTagNameMap[K]
- query
Selector <K>(selectors): SVGElementTagNameMap[K] Type Parameters
- K extends keyof SVGElementTagNameMap
Parameters
- selectors: K
Returns SVGElementTagNameMap[K]
- query
Selector <K>(selectors): MathMLElementTagNameMap[K] Type Parameters
- K extends keyof MathMLElementTagNameMap
Parameters
- selectors: K
Returns MathMLElementTagNameMap[K]
- query
Selector <K>(selectors): HTMLElementDeprecatedTagNameMap[K] Type Parameters
- K extends keyof HTMLElementDeprecatedTagNameMap
Parameters
- selectors: K
Returns HTMLElementDeprecatedTagNameMap[K]
- query
Selector <E>(selectors): E Type Parameters
Parameters
- selectors: string
Returns E
querySelectorAll
- query
Selector <K>(selectors): NodeListOf<HTMLElementTagNameMap[K]>All Returns all element descendants of node that match selectors.
Type Parameters
- K extends keyof HTMLElementTagNameMap
Parameters
- selectors: K
Returns NodeListOf<HTMLElementTagNameMap[K]>
- query
Selector <K>(selectors): NodeListOf<SVGElementTagNameMap[K]>All Type Parameters
- K extends keyof SVGElementTagNameMap
Parameters
- selectors: K
Returns NodeListOf<SVGElementTagNameMap[K]>
- query
Selector <K>(selectors): NodeListOf<MathMLElementTagNameMap[K]>All Type Parameters
- K extends keyof MathMLElementTagNameMap
Parameters
- selectors: K
Returns NodeListOf<MathMLElementTagNameMap[K]>
- query
Selector <K>(selectors): NodeListOf<HTMLElementDeprecatedTagNameMap[K]>All Type Parameters
- K extends keyof HTMLElementDeprecatedTagNameMap
Parameters
- selectors: K
Returns NodeListOf<HTMLElementDeprecatedTagNameMap[K]>
- query
Selector <E>(selectors): NodeListOf<E>All Type Parameters
Parameters
- selectors: string
Returns NodeListOf<E>
releaseEvents
removeChild
removeEventListener
- remove
Event <K>(type, listener, options?): voidListener Removes the event listener in target's event listener list with the same type, callback, and options.
Type Parameters
- K extends keyof DocumentEventMap
Parameters
- type: K
- listener: ((this: HTMLDocument, ev: DocumentEventMap[K]) => any)
- (this, ev): any
Parameters
- this: HTMLDocument
- ev: DocumentEventMap[K]
Returns any
Optional
options: boolean | EventListenerOptions
Returns void
- remove
Event (type, listener, options?): voidListener Removes the event listener in target's event listener list with the same type, callback, and options.
Parameters
- type: string
- listener: EventListenerOrEventListenerObject
Optional
options: boolean | EventListenerOptions
Returns void
replaceChild
replaceChildren
- replace
Children (...nodes): void Replace all children of node with nodes, while replacing strings in nodes with equivalent Text nodes.
Throws a "HierarchyRequestError" DOMException if the constraints of the node tree are violated.
Parameters
Rest
...nodes: (string | Node)[]
Returns void
requestStorageAccess
startViewTransition
- start
View (callbackOptions?): ViewTransitionTransition Parameters
Optional
callbackOptions: UpdateCallback
Returns ViewTransition
Deprecated
use Document