Search notes:

HTMLElement

Class inheritance

HTMLElement inherits from Element.
All classes that represent HTML elements inherit from HTMLElement.
Thus, HTMLElement (together with Element from which it inherits) provides the functionality that is shared by all HTML elements, such as
In most cases, the name of the child classes is constructed from the name of HTML element like so: <body>HTMLBodyElement, <span>HTMLSpanElement etc.
But there are also exceptions to the rule: <a>HTMLLinkElement, <h1> through <h6>HTMLHeadingElement, <caption>HTMLTableCaptionElement and others.

Properties, methods and events

accessKey
accessKeyLabel
attributeStyleMap (?) A StylePropertyMap object.
attachInternals()
beforeinput Event
blur() Removes keyboard focus, compare with focus()
change Event
click()
contentEditable
contextMenu Non-standard, Deprecated, a (potentially null) HTMLMenuElement.
copy Event
cut Event
dataset A DOMStringMap object which allows to read and write to/from an HTML element's custom data attributs (i.e. values of attributes whose names start with data-).
dir
drag Event
dragend Event
dragenter Event
dragleave Event
dragover Event
dragstart Event
drop Event
enterKeyHint
focus() Set current keyboard focus to element, compare with blur()
hidden Corresponds to the value of the element's global attribute hidden.
inert
innerText When read: The node's and its descendants' rendered text (approximately that which would be copied into the clipboard). When written: replaces the node and its descendants with the text. Compare with outerText and Element.setHTML.
input Event
inputMode
isContentEditable
lang
mscandidatewindowhide Non-standard, Event
mscandidatewindowshow Non-standard, Event
mscandidatewindowupdate Non-standard, Event
noModule (?) Used by Content Security Policy.
nonce
offsetParent The Element from which all offset* calculations are currently computed. See also this example.
offsetLeft, offsetTop Distance of the elements left/top border to the corresponding border of offsetParent. See also this example.
offsetHeight, offsetWidth See also this DOM example and this example.
outerText Compare with innerText
paste Event
style A CSSStyleDeclaration object which represents element's style/CSS attribute declarations.
tabIndex
title

See also

HTMLMediaElement, HTMLCanvasElement, HTMLUnknownElement

Index