Element

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 Element . 例如, 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 Element .

特性

继承特性来自其父级接口 Node , and by extension that interface's parent, EventTarget . It implements the properties of ParentNode , ChildNode , NonDocumentTypeChildNode , and Animatable .

Element.attributes 只读
返回 NamedNodeMap object containing the assigned attributes of the corresponding HTML element.
Element.classList 只读
返回 DOMTokenList containing the list of class attributes.
Element.className
DOMString representing the class of the element.
Element.clientHeight 只读
返回 Number representing the inner height of the element.
Element.clientLeft 只读
返回 Number representing the width of the left border of the element.
Element.clientTop 只读
返回 Number representing the width of the top border of the element.
Element.clientWidth 只读
返回 Number representing the inner width of the element.
Element.computedName 只读
返回 DOMString containing the label exposed to accessibility.
Element.computedRole 只读
返回 DOMString containing the ARIA role that has been applied to a particular element.
Element.id
DOMString 表示元素的 ID。
Element.innerHTML
DOMString 表示元素内容的标记。
Element.localName 只读
A DOMString representing the local part of the qualified name of the element.
Element.namespaceURI 只读
The namespace URI of the element, or null if it is no namespace.

注意: In Firefox 3.5 and earlier, HTML elements are in no namespace. In later versions, HTML elements are in the http://www.w3.org/1999/xhtml namespace in both HTML and XML trees.

NonDocumentTypeChildNode.nextElementSibling 只读
Is an Element , the element immediately following the given one in the tree, or null if there's no sibling node.
Element.outerHTML
DOMString representing the markup of the element including its content. When used as a setter, replaces the element with nodes parsed from the given string.
Element.part
Represents the part identifier(s) of the element (i.e. set using the part attribute), returned as a DOMTokenList .
Element.prefix 只读
A DOMString representing the namespace prefix of the element, or null if no prefix is specified.
NonDocumentTypeChildNode.previousElementSibling 只读
Element , the element immediately preceding the given one in the tree, or null if there is no sibling element.
Element.scrollHeight 只读
返回 Number representing the scroll view height of an element.
Element.scrollLeft
Number representing the left scroll offset of the element.
Element.scrollLeftMax 只读
返回 Number representing the maximum left scroll offset possible for the element.
Element.scrollTop
A Number representing number of pixels the top of the document is scrolled vertically.
Element.scrollTopMax 只读
返回 Number representing the maximum top scroll offset possible for the element.
Element.scrollWidth 只读
返回 Number representing the scroll view width of the element.
Element.shadowRoot 只读
Returns the open shadow root that is hosted by the element, or null if no open shadow root is present.
Element.openOrClosedShadowRoot 只读
Returns the shadow root that is hosted by the element, regardless if its open or closed. Available only to WebExtensions .
Element.slot
Returns the name of the shadow DOM slot the element is inserted in.
Element.tabStop
Boolean indicating if the element can receive input focus via the tab key.
Element.tagName 只读
返回 String with the name of the tag for the given element.
Element.undoManager 只读
返回 UndoManager associated with the element.
Element.undoScope
Boolean indicating if the element is an undo scope host, or not.

注意: DOM Level 3 defined namespaceURI , localName and prefix on the Node interface. In DOM4 they were moved to Element .

This change is implemented in Chrome since version 46.0 and Firefox since version 48.0.

Properties included from Slotable

Element interface includes the following property, defined on the Slotable mixin.

Slotable.assignedSlot 只读
返回 HTMLSlotElement representing the <slot> the node is inserted in.

事件处理程序

Element.onfullscreenchange
An event handler for the fullscreenchange event, which is sent when the element enters or exits full-screen mode. This can be used to watch both for successful expected transitions, but also to watch for unexpected changes, such as when your app is running in the background.
Element.onfullscreenerror
An event handler for the fullscreenerror event, which is sent when an error occurs while attempting to change into full-screen mode.

方法

Inherits methods from its parents Node , and its own parent, EventTarget , and implements those of ParentNode , ChildNode , NonDocumentTypeChildNode , and Animatable .

EventTarget.addEventListener()
Registers an event handler to a specific event type on the element.
Element.attachShadow()
Attaches a shadow DOM tree to the specified element and returns a reference to its ShadowRoot .
Element.animate()
A shortcut method to create and run an animation on an element. Returns the created Animation object instance.
Element.closest()
返回 Element which is the closest ancestor of the current element (or the current element itself) which matches the selectors given in parameter.
Element.createShadowRoot()
创建 shadow DOM on on the element, turning it into a shadow host. Returns a ShadowRoot .
Element.computedStyleMap()
返回 StylePropertyMapReadOnly interface which provides a read-only representation of a CSS declaration block that is an alternative to CSSStyleDeclaration .
EventTarget.dispatchEvent()
Dispatches an event to this node in the DOM and returns a Boolean that indicates whether no handler canceled the event.
Element.getAnimations()
Returns an array of Animation objects currently active on the element.
Element.getAttribute()
Retrieves the value of the named attribute from the current node and returns it as an Object .
Element.getAttributeNames()
Returns an array of attribute names from the current element.
Element.getAttributeNS()
Retrieves the value of the attribute with the specified name and namespace, from the current node and returns it as an Object .
Element.getBoundingClientRect()
Returns the size of an element and its position relative to the viewport.
Element.getClientRects()
Returns a collection of rectangles that indicate the bounding rectangles for each line of text in a client.
Element.getElementsByClassName()
Returns a live HTMLCollection that contains all descendants of the current element that possess the list of classes given in the parameter.
Element.getElementsByTagName()
Returns a live HTMLCollection containing all descendant elements, of a particular tag name, from the current element.
Element.getElementsByTagNameNS()
Returns a live HTMLCollection containing all descendant elements, of a particular tag name and namespace, from the current element.
Element.hasAttribute()
返回 Boolean indicating if the element has the specified attribute or not.
Element.hasAttributeNS()
返回 Boolean indicating if the element has the specified attribute, in the specified namespace, or not.
Element.hasAttributes()
返回 Boolean indicating if the element has one or more HTML attributes present.
Element.hasPointerCapture()
Indicates whether the element on which it is invoked has pointer capture for the pointer identified by the given pointer ID.
Element.insertAdjacentElement()
Inserts a given element node at a given position relative to the element it is invoked upon.
Element.insertAdjacentHTML()
Parses the text as HTML or XML and inserts the resulting nodes into the tree in the position given.
Element.insertAdjacentText()
Inserts a given text node at a given position relative to the element it is invoked upon.
Element.matches()
返回 Boolean indicating whether or not the element would be selected by the specified selector string.
Element.pseudo()
返回 CSSPseudoElement representing the child pseudo-element matched by the specified pseudo-element selector.
Element.querySelector()
Returns the first Node which matches the specified selector string relative to the element.
Element.querySelectorAll()
返回 NodeList of nodes which match the specified selector string relative to the element.
Element.releasePointerCapture()
Releases (stops) pointer capture that was previously set for a specific pointer event .
ChildNode.remove()
Removes the element from the children list of its parent.
Element.removeAttribute()
Removes the named attribute from the current node.
Element.removeAttributeNS()
Removes the attribute with the specified name and namespace, from the current node.
EventTarget.removeEventListener()
Removes an event listener from the element.
Element.requestFullscreen()
Asynchronously asks the browser to make the element full-screen.
Element.requestPointerLock()
Allows to asynchronously ask for the pointer to be locked on the given element.
Element.scroll()
Scrolls to a particular set of coordinates inside a given element.
Element.scrollBy()
Scrolls an element by the given amount.
Element.scrollIntoView()
Scrolls the page until the element gets into the view.
Element.scrollTo()
Scrolls to a particular set of coordinates inside a given element.
Element.setAttribute()
Sets the value of a named attribute of the current node.
Element.setAttributeNS()
Sets the value of the attribute with the specified name and namespace, from the current node.
Element.setCapture()
Sets up mouse event capture, redirecting all mouse events to this element.
Element.setPointerCapture()
Designates a specific element as the capture target of future pointer events .
Element.toggleAttribute()
Toggles a boolean attribute, removing it if it is present and adding it if it is not present, on the specified element.

Obsolete methods

Element.getAttributeNode()
Retrieves the node representation of the named attribute from the current node and returns it as an Attr .
Element.getAttributeNodeNS()
Retrieves the node representation of the attribute with the specified name and namespace, from the current node and returns it as an Attr .
Element.removeAttributeNode()
Removes the node representation of the named attribute from the current node.
Element.setAttributeNode()
Sets the node representation of the named attribute from the current node.
Element.setAttributeNodeNS()
Sets the node representation of the attribute with the specified name and namespace, from the current node.

Events

监听这些事件使用 addEventListener() 或通过把事件监听器赋值给 on eventname 特性为此接口。

cancel
Fires on a <dialog> when the user instructs the browser that they wish to dismiss the current open dialog. For example, the browser might fire this event when the user presses the Esc key or clicks a "Close dialog" button which is part of the browser's UI.
Also available via the oncancel 特性。
error
Fired when a resource failed to load, or can't be used. For example, if a script has an execution error or an image can't be found or is invalid.
Also available via the onerror 特性。
scroll
Fired when the document view or an element has been scrolled.
Also available via the onscroll 特性。
select
Fired when some text has been selected.
Also available via the onselect 特性。
show
Fired when a contextmenu event was fired on/bubbled to an element that has a contextmenu 属性。
Also available via the onshow 特性。
wheel
Fired when the user rotates a wheel button on a pointing device (typically a mouse).
Also available via the onwheel 特性。

剪贴板事件

copy
Fired when the user initiates a copy action through the browser's user interface.
Also available via the oncopy 特性。
cut
Fired when the user initiates a cut action through the browser's user interface.
Also available via the oncut 特性。
paste
Fired when the user initiates a paste action through the browser's user interface.
Also available via the onpaste 特性。

Composition events

compositionend
Fired when a text composition system such as an input method editor completes or cancels the current composition session.
compositionstart
Fired when a text composition system such as an input method editor starts a new composition session.
compositionupdate
Fired when a new character is received in the context of a text composition session controlled by a text composition system such as an input method editor .

聚焦事件

blur
Fired when an element has lost focus.
Also available via the onblur 特性。
focus
Fired when an element has gained focus.
Also available via the onfocus property
focusin
Fired when an element is about to gain focus.
focusout
Fired when an element is about to lose focus.

Fullscreen events

fullscreenchange
Sent to an Element when it transitions into or out of full-screen 模式。
Also available via the onfullscreenchange 特性。
fullscreenerror
Sent to an Element if an error occurs while attempting to switch it into or out of full-screen 模式。
Also available via the onfullscreenerror 特性。

Keyboard events

keydown
Fired when a key is pressed.
Also available via the onkeydown 特性。
keypress
Fired when a key that produces a character value is pressed down.
Also available via the onkeypress 特性。
keyup
Fired when a key is released.
Also available via the onkeyup 特性。

Mouse events

auxclick
Fired when a non-primary pointing device button (e.g., any mouse button other than the left button) has been pressed and released on an element.
Also available via the onauxclick 特性。
click
Fired when a pointing device button (e.g., a mouse's primary button) is pressed and released on a single element.
Also available via the onclick 特性。
contextmenu
Fired when the user attempts to open a context menu.
Also available via the oncontextmenu 特性。
dblclick
Fired when a pointing device button (e.g., a mouse's primary button) is clicked twice on a single element.
Also available via the ondblclick 特性。
DOMActivate
Occurs when an element is activated, for instance, through a mouse click or a keypress.
mousedown
Fired when a pointing device button is pressed on an element.
Also available via the onmousedown 特性。
mouseenter
Fired when a pointing device (usually a mouse) is moved over the element that has the listener attached.
Also available via the onmouseenter 特性。
mouseleave
Fired when the pointer of a pointing device (usually a mouse) is moved out of an element that has the listener attached to it.
Also available via the onmouseleave 特性。
mousemove
Fired when a pointing device (usually a mouse) is moved while over an element.
Also available via the onmousemove 特性。
mouseout
Fired when a pointing device (usually a mouse) is moved off the element to which the listener is attached or off one of its children.
Also available via the onmouseout 特性。
mouseover
Fired when a pointing device is moved onto the element to which the listener is attached or onto one of its children.
Also available via the onmouseover 特性。
mouseup
Fired when a pointing device button is released on an element.
Also available via the onmouseup 特性。
webkitmouseforcechanged
Fired each time the amount of pressure changes on the trackpadtouchscreen.
webkitmouseforcedown
Fired after the mousedown event as soon as sufficient pressure has been applied to qualify as a "force click".
webkitmouseforcewillbegin
Fired before the mousedown 事件。
webkitmouseforceup
Fired after the webkitmouseforcedown event as soon as the pressure has been reduced sufficiently to end the "force click".

Touch events

touchcancel
Fired when one or more touch points have been disrupted in an implementation-specific manner (for example, too many touch points are created).
Also available via the ontouchcancel 特性。
touchend
Fired when one or more touch points are removed from the touch surface.
Also available via the ontouchend property
touchmove
Fired when one or more touch points are moved along the touch surface.
Also available via the ontouchmove property
touchstart
Fired when one or more touch points are placed on the touch surface.
Also available via the ontouchstart property

规范

规范 状态 Comment
CSS Pseudo-Elements Level 4
The definition of 'Element' in that specification.
工作草案 添加 pseudo() 方法。
Web 动画 工作草案 添加 getAnimations() 方法。
UndoManager and DOMTransaction
The definition of 'Element' in that specification.
编者草案 添加 undoScope and undoManager 特性。
Pointer Events – Level 2
The definition of 'Element' in that specification.
Recommendation Added the following event handlers: ongotpointercapture and onlostpointercapture .
Added the following methods: setPointerCapture() and releasePointerCapture() .
指针事件
The definition of 'Element' in that specification.
Obsolete Added the following event handlers: ongotpointercapture and onlostpointercapture .
Added the following methods: setPointerCapture() and releasePointerCapture() .
Selectors API Level 1
The definition of 'Element' in that specification.
Obsolete Added the following methods: querySelector() and querySelectorAll() .
Pointer Lock
The definition of 'Element' in that specification.
候选推荐 添加 requestPointerLock() 方法。
全屏 API
The definition of 'Element' in that specification.
实时标准 添加 requestFullscreen() 方法。
DOM 剖析和序列化
The definition of 'Element' in that specification.
工作草案 Added the following properties: innerHTML ,和 outerHTML .
Added the following method: insertAdjacentHTML() .
CSS Object Model (CSSOM) View Module
The definition of 'Element' in that specification.
工作草案 Added the following properties: scrollTop , scrollLeft , scrollWidth , scrollHeight , clientTop , clientLeft , clientWidth ,和 clientHeight .
Added the following methods: getClientRects() , getBoundingClientRect() , scroll() , scrollBy() , scrollTo() and scrollIntoView() .
Element Traversal Specification
The definition of 'Element' in that specification.
Obsolete Added inheritance of the ElementTraversal 接口。
DOM
The definition of 'Element' in that specification.
实时标准 Added the following methods: closest() , insertAdjacentElement() and insertAdjacentText() .
移动 hasAttributes() Node interface to this one.
DOM4
The definition of 'Element' in that specification.
Obsolete Removed the following methods: setIdAttribute() , setIdAttributeNS() ,和 setIdAttributeNode() .
Modified the return value of getElementsByTagName() and getElementsByTagNameNS() .
Removed the schemaTypeInfo 特性。
Document Object Model (DOM) Level 3 Core Specification
The definition of 'Element' in that specification.
Obsolete Added the following methods: setIdAttribute() , setIdAttributeNS() ,和 setIdAttributeNode() . These methods were never implemented and have been removed in later specifications.
添加 schemaTypeInfo property. This property was never implemented and has been removed in later specifications.
Document Object Model (DOM) Level 2 Core Specification
The definition of 'Element' in that specification.
Obsolete normalize() method has been moved to Node .
Document Object Model (DOM) Level 1 Specification
The definition of 'Element' in that specification.
Obsolete 初始定义。

浏览器兼容性

更新 GitHub 上的兼容性数据
Desktop Mobile
Chrome Edge Firefox Internet Explorer Opera Safari Android webview Chrome for Android Firefox for Android Opera for Android Safari on iOS Samsung Internet
Element Chrome 1 Edge 12 Firefox 1 IE 4 Opera 8 Safari 1.3 WebView Android 1 Chrome Android 18 Firefox Android 4 Opera Android 10.1 Safari iOS 1 Samsung Internet Android 1.0
DOMActivate event
弃用 非标
Chrome Yes Edge 79 Firefox Yes IE No Opera No Safari Yes WebView Android ? Chrome Android Yes Firefox Android Yes Opera Android No Safari iOS ? Samsung Internet Android Yes
DOMMouseScroll event
弃用 非标
Chrome No Edge No Firefox 1 IE No Opera No Safari No WebView Android No Chrome Android No Firefox Android 4 Opera Android No Safari iOS No Samsung Internet Android No
MozMousePixelScroll event
弃用 非标
Chrome No Edge ≤18 — 79 Firefox Yes IE No Opera No Safari No WebView Android No Chrome Android No Firefox Android Yes Opera Android No Safari iOS No Samsung Internet Android No
MSGestureChange event
非标
Chrome No Edge 12 — 79 Firefox No IE 10 Opera No Safari No WebView Android No Chrome Android No Firefox Android No Opera Android No Safari iOS No Samsung Internet Android No
MSGestureEnd event
非标
Chrome No Edge 12 — 79 Firefox No IE 10 Opera No Safari No WebView Android No Chrome Android No Firefox Android No Opera Android No Safari iOS No Samsung Internet Android No
MSGestureHold event
非标
Chrome No Edge 12 — 79 Firefox No IE 10 Opera No Safari No WebView Android No Chrome Android No Firefox Android No Opera Android No Safari iOS No Samsung Internet Android No
MSGestureStart event
非标
Chrome No Edge 12 — 79 Firefox No IE 10 Opera No Safari No WebView Android No Chrome Android No Firefox Android No Opera Android No Safari iOS No Samsung Internet Android No
MSGestureTap event
非标
Chrome No Edge 12 — 79 Firefox No IE 10 Opera No Safari No WebView Android No Chrome Android No Firefox Android No Opera Android No Safari iOS No Samsung Internet Android No
MSInertiaStart event
非标
Chrome No Edge 12 — 79 Firefox No IE 10 Opera No Safari No WebView Android No Chrome Android No Firefox Android No Opera Android No Safari iOS No Samsung Internet Android No
MSManipulationStateChanged event
非标
Chrome No Edge 12 — 79 Firefox No IE Yes Opera No Safari No WebView Android No Chrome Android No Firefox Android No Opera Android No Safari iOS No Samsung Internet Android No
accessKey Chrome No
不支持 No
Implemented on HTMLElement .
Edge No
不支持 No
Implemented on HTMLElement .
Firefox ? IE ? Opera No
不支持 No
Implemented on HTMLElement .
Safari ? WebView Android No
不支持 No
Implemented on HTMLElement .
Chrome Android No
不支持 No
Implemented on HTMLElement .
Firefox Android ? Opera Android No
不支持 No
Implemented on HTMLElement .
Safari iOS ? Samsung Internet Android No
不支持 No
Implemented on HTMLElement .
afterscriptexecute event
非标
Chrome No Edge No Firefox 2 IE ? Opera No Safari No WebView Android No Chrome Android No Firefox Android 4 Opera Android No Safari iOS No Samsung Internet Android No
animate
Chrome 36 Edge 79 Firefox 48 IE No Opera 23 Safari Yes
Disabled
Yes
Disabled
Disabled This feature is behind the Web 动画 preference and the CSS Animations via Web Animations preference.
WebView Android 37 Chrome Android 36 Firefox Android 48 Opera Android 24 Safari iOS 13.4 Samsung Internet Android 3.0
attachShadow Chrome 53 Edge 79 Firefox 63
63
不支持 59 — 63
Disabled
Disabled From version 59 until version 63 (exclusive): this feature is behind the dom.webcomponents.shadowdom.enabled preference (needs to be set to true ). To change preferences in Firefox, visit about:config.
IE No Opera 40 Safari 10 WebView Android 53 Chrome Android 53 Firefox Android 63
63
不支持 59 — 63
Disabled
Disabled From version 59 until version 63 (exclusive): this feature is behind the dom.webcomponents.shadowdom.enabled preference (needs to be set to true ). To change preferences in Firefox, visit about:config.
Opera Android 41 Safari iOS 10 Samsung Internet Android 6.0
attributes Chrome 26 Edge 12 Firefox 22 IE 5.5 Opera 8 Safari 6 WebView Android ≤37 Chrome Android 26 Firefox Android 22 Opera Android 10.1 Safari iOS 6 Samsung Internet Android 1.5
attributeStyleMap Chrome 66 Edge ≤79 Firefox ? IE ? Opera ? Safari ? WebView Android 66 Chrome Android 66 Firefox Android ? Opera Android ? Safari iOS ? Samsung Internet Android 9.0
auxclick event Chrome 55 Edge ≤79 Firefox 53
53
Starting in Firefox 68, the auxclick event is used to trigger the new tab on middle-click action; previously, this had been done with the click event. Apps can prevent middle-click from opening new tabs (or middle-click to paste, if that feature is enabled) by intercepting auxclick on links, and auxclick event handlers can now open popups without triggering the popup blocker.
IE No Opera 42 Safari No WebView Android 55 Chrome Android 55 Firefox Android 53 Opera Android 42 Safari iOS No Samsung Internet Android 6.0
beforescriptexecute event
非标
Chrome No Edge No Firefox 2 IE ? Opera No Safari No WebView Android No Chrome Android No Firefox Android 4 Opera Android No Safari iOS No Samsung Internet Android No
blur event Chrome 1 Edge 12 Firefox 24
24
不支持 6 — 24
The interface for this event is Event , not FocusEvent .
IE 9 Opera 11.6 Safari 3.1 WebView Android 1 Chrome Android 18 Firefox Android 24
24
不支持 6 — 24
The interface for this event is Event , not FocusEvent .
Opera Android 12.1 Safari iOS 2 Samsung Internet Android 1.0
classList Chrome 8 Edge 16
16
不支持 12 — 16
Not supported for SVG elements.
Firefox 3.6 IE 部分支持 10
部分支持 10
Not supported for SVG elements.
Opera 11.5 Safari 6 WebView Android ≤37 Chrome Android 18 Firefox Android 4 Opera Android 11.5 Safari iOS 5 Samsung Internet Android 1.0
className Chrome 43 Edge 12 Firefox 1 IE 8 Opera 8 Safari 6 WebView Android 43 Chrome Android 43 Firefox Android 4 Opera Android 10.1 Safari iOS 6 Samsung Internet Android 4.0
click event Chrome 1 Edge 12 Firefox 6
6
Beginning in Firefox 68, Firefox no longer incorrectly sends a click event for buttons other than the primary mouse button; previouly, there were circumstances in which this would occur. One example: middle-clicking a link would send a click to the document's <html> 元素。
IE 9 Opera 11.6 Safari 3 WebView Android 1 Chrome Android 18 Firefox Android 6 Opera Android 12.1 Safari iOS 1 Samsung Internet Android 1.0
clientHeight Chrome 43 Edge 12 Firefox 1 IE 6 Opera 8 Safari 6 WebView Android 43 Chrome Android 43 Firefox Android 4 Opera Android 10.1 Safari iOS 6 Samsung Internet Android 4.0
clientLeft Chrome 43 Edge 12 Firefox 1 IE 6 Opera 8 Safari 6 WebView Android 43 Chrome Android 43 Firefox Android 4 Opera Android 10.1 Safari iOS 6 Samsung Internet Android 4.0
clientTop Chrome 43 Edge 12 Firefox 1 IE 6 Opera 8 Safari 6 WebView Android 43 Chrome Android 43 Firefox Android 4 Opera Android 10.1 Safari iOS 6 Samsung Internet Android 4.0
clientWidth Chrome 43 Edge 12 Firefox 1 IE 6 Opera 8 Safari 6 WebView Android 43 Chrome Android 43 Firefox Android 4 Opera Android 10.1 Safari iOS 6 Samsung Internet Android 4.0
closest Chrome 41 Edge 15 Firefox 35 IE No Opera 28 Safari 6 WebView Android 41 Chrome Android 41 Firefox Android 35 Opera Android 28 Safari iOS 9 Samsung Internet Android 4.0
compositionend event Chrome Yes Edge 12 Firefox 9 IE Yes Opera Yes Safari Yes WebView Android Yes Chrome Android Yes Firefox Android Yes Opera Android ? Safari iOS ? Samsung Internet Android Yes
compositionstart event Chrome Yes Edge 12 Firefox 9 IE Yes Opera Yes Safari Yes WebView Android Yes Chrome Android Yes Firefox Android Yes Opera Android ? Safari iOS ? Samsung Internet Android Yes
compositionupdate event Chrome Yes Edge 12 Firefox 9 IE Yes Opera Yes Safari Yes WebView Android Yes Chrome Android Yes Firefox Android Yes Opera Android ? Safari iOS ? Samsung Internet Android Yes
computedStyleMap
Chrome 66 Edge 79 Firefox No IE No Opera 53 Safari No WebView Android 66 Chrome Android 66 Firefox Android No Opera Android 47 Safari iOS No Samsung Internet Android 9.0
contextmenu event Chrome 1 Edge 12 Firefox 6 IE 9 Opera 10.5 Safari 3 WebView Android 1 Chrome Android 18 Firefox Android 6 Opera Android 11.1 Safari iOS 1 Samsung Internet Android 1.0
copy event Chrome 58 Edge ≤18 Firefox Yes IE Yes Opera 45 Safari Yes WebView Android 58 Chrome Android 58 Firefox Android Yes Opera Android 43 Safari iOS Yes Samsung Internet Android 7.0
createShadowRoot
弃用 非标
Chrome 35
35
In Chrome 45, the ability to have multiple shadow roots was deprecated.
不支持 25 — ?
Prefixed
Prefixed Implemented with the vendor prefix: webkit
Edge 79 Firefox 59 — 61
Disabled
不支持 59 — 61
Disabled
Disabled From version 59 until version 61 (exclusive): this feature is behind the dom.webcomponents.shadowdom.enabled preference (needs to be set to true ). To change preferences in Firefox, visit about:config.
不支持 29 — 59
Disabled
Disabled From version 29 until version 59 (exclusive): this feature is behind the dom.webcomponents.enabled preference (needs to be set to true ). To change preferences in Firefox, visit about:config.
IE No Opera 22
22
In Opera 32, the ability to have multiple shadow roots was deprecated.
不支持 15 — ?
Prefixed
Prefixed Implemented with the vendor prefix: webkit
Safari No WebView Android 37
37
In version 45, the ability to have multiple shadow roots was deprecated.
不支持 ? — ?
Prefixed
Prefixed Implemented with the vendor prefix: webkit
Chrome Android 35
35
In Chrome 45, the ability to have multiple shadow roots was deprecated.
不支持 25 — ?
Prefixed
Prefixed Implemented with the vendor prefix: webkit
Firefox Android 59 — 61
Disabled
不支持 59 — 61
Disabled
Disabled From version 59 until version 61 (exclusive): this feature is behind the dom.webcomponents.shadowdom.enabled preference (needs to be set to true ). To change preferences in Firefox, visit about:config.
不支持 29 — 59
Disabled
Disabled From version 29 until version 59 (exclusive): this feature is behind the dom.webcomponents.enabled preference (needs to be set to true ). To change preferences in Firefox, visit about:config.
Opera Android 22
22
In Opera 32, the ability to have multiple shadow roots was deprecated.
不支持 14 — ?
Prefixed
Prefixed Implemented with the vendor prefix: webkit
Safari iOS No Samsung Internet Android 5.0
5.0
In Samsung Internet 5.0, the ability to have multiple shadow roots was deprecated.
不支持 4.0 — ?
Prefixed
Prefixed Implemented with the vendor prefix: webkit
currentStyle
非标
Chrome No Edge No Firefox No IE 6 Opera No Safari No WebView Android No Chrome Android No Firefox Android No Opera Android No Safari iOS No Samsung Internet Android No
cut event Chrome 58 Edge ≤18 Firefox Yes IE Yes Opera 45 Safari Yes WebView Android 58 Chrome Android 58 Firefox Android Yes Opera Android 43 Safari iOS Yes Samsung Internet Android 7.0
dblclick event Chrome 1 Edge 12 Firefox 6
6
Starting in Firefox 68, dblclick events are only sent for the primary mouse button, per the specification.
IE 11 Opera 11.6 Safari 3 WebView Android No Chrome Android No Firefox Android 6 Opera Android 12.1 Safari iOS 1 Samsung Internet Android No
error event Chrome Yes Edge ≤79 Firefox Yes IE ? Opera ? Safari ? WebView Android Yes Chrome Android Yes Firefox Android Yes Opera Android ? Safari iOS ? Samsung Internet Android Yes
focus event Chrome 1 Edge 12 Firefox 24
24
不支持 6 — 24
The interface for this event is Event , not FocusEvent .
IE 9 Opera 11.6 Safari 3.1 WebView Android 1 Chrome Android 18 Firefox Android 24
24
不支持 6 — 24
The interface for this event is Event , not FocusEvent .
Opera Android 12.1 Safari iOS 2 Samsung Internet Android 1.0
focusin event Chrome 1 Edge 12 Firefox 52 IE 9 Opera 11.6 Safari 5 WebView Android 1 Chrome Android 18 Firefox Android 52 Opera Android 12.1 Safari iOS 4.2 Samsung Internet Android 1.0
focusout event Chrome 1 Edge 12 Firefox 52 IE 9 Opera 11.6 Safari 5 WebView Android 1 Chrome Android 18 Firefox Android 52 Opera Android 12.1 Safari iOS 4.2 Samsung Internet Android 1.0
fullscreenchange event Chrome 57 Edge ≤79 Firefox 64
64
不支持 10 — 64
Alternate Name
Alternate Name Uses the non-standard name: mozfullscreenchange
IE ? Opera 44 Safari ? WebView Android 57 Chrome Android 57 Firefox Android 64
64
不支持 10 — 64
Alternate Name
Alternate Name Uses the non-standard name: mozfullscreenchange
Opera Android 43 Safari iOS ? Samsung Internet Android 7.0
fullscreenerror event Chrome 57 Edge ≤79 Firefox 64
64
不支持 10 — 64
Alternate Name
Alternate Name Uses the non-standard name: mozfullscreenerror
IE ? Opera 44 Safari ? WebView Android 57 Chrome Android 57 Firefox Android 64
64
不支持 10 — 64
Alternate Name
Alternate Name Uses the non-standard name: mozfullscreenerror
Opera Android 43 Safari iOS ? Samsung Internet Android 7.0
gesturechange event
非标
Chrome No Edge No Firefox No IE No Opera No Safari 9.1 WebView Android No Chrome Android No Firefox Android No Opera Android No Safari iOS 2 Samsung Internet Android No
gestureend event
非标
Chrome No Edge No Firefox No IE No Opera No Safari 9.1 WebView Android No Chrome Android No Firefox Android No Opera Android No Safari iOS 2 Samsung Internet Android No
gesturestart event
非标
Chrome No Edge No Firefox No IE No Opera No Safari 9.1 WebView Android No Chrome Android No Firefox Android No Opera Android No Safari iOS 2 Samsung Internet Android No
getAnimations
Chrome 79
Disabled
79
Disabled
Disabled From version 79: this feature is behind the Experimental Web Platform Features preference. To change preferences in Chrome, visit chrome://flags.
不支持 67 — 79
Disabled
Does not support the subtree 选项。
Disabled From version 67 until version 79 (exclusive): this feature is behind the Experimental Web Platform Features preference. To change preferences in Chrome, visit chrome://flags.
不支持 44 — 67
Disabled
Does not automatically flush pending style changes and does not support the subtree 选项。
Disabled From version 44 until version 67 (exclusive): this feature is behind the Experimental Web Platform Features preference. To change preferences in Chrome, visit chrome://flags.
不支持 38 — 44
Alternate Name Disabled
Does not automatically flush pending style changes and does not support the subtree 选项。
Alternate Name Uses the non-standard name: getAnimationPlayers
Disabled From version 38 until version 44 (exclusive): this feature is behind the Experimental Web Platform Features preference. To change preferences in Chrome, visit chrome://flags.
Edge 79
Disabled
79
Disabled
Disabled From version 79: this feature is behind the Experimental Web Platform Features preference.
Firefox 75
75
不支持 63 — 75
Disabled
Disabled From version 63 until version 75 (exclusive): this feature is behind the dom.animations-api.getAnimations.enabled preference. To change preferences in Firefox, visit about:config.
不支持 48 — 63
Disabled
Disabled From version 48 until version 63 (exclusive): this feature is behind the dom.animations-api.core.enabled preference. To change preferences in Firefox, visit about:config.
不支持 40 — 48
Disabled
Does not support the subtree 选项。
Disabled From version 40 until version 48 (exclusive): this feature is behind the dom.animations-api.core.enabled preference. To change preferences in Firefox, visit about:config.
不支持 35 — 40
Alternate Name Disabled
Does not support the subtree 选项。
Alternate Name Uses the non-standard name: getAnimationPlayers
Disabled From version 35 until version 40 (exclusive): this feature is behind the dom.animations-api.core.enabled preference. To change preferences in Firefox, visit about:config.
不支持 33 — 35
Alternate Name Disabled
Does not automatically flush pending style changes and does not support the subtree 选项。
Alternate Name Uses the non-standard name: getAnimationPlayers
Disabled From version 33 until version 35 (exclusive): this feature is behind the dom.animations-api.core.enabled preference. To change preferences in Firefox, visit about:config.
IE No Opera 66
Disabled
66
Disabled
Disabled From version 66: this feature is behind the Experimental Web Platform Features preference.
不支持 54 — 66
Disabled
Does not support the subtree 选项。
Disabled From version 54 until version 66 (exclusive): this feature is behind the Experimental Web Platform Features preference.
不支持 31 — 54
Disabled
Does not automatically flush pending style changes and does not support the subtree 选项。
Disabled From version 31 until version 54 (exclusive): this feature is behind the Experimental Web Platform Features preference.
不支持 25 — 31
Alternate Name Disabled
Does not automatically flush pending style changes and does not support the subtree 选项。
Alternate Name Uses the non-standard name: getAnimationPlayers
Disabled From version 25 until version 31 (exclusive): this feature is behind the Experimental Web Platform Features preference.
Safari 部分支持 Partial
Disabled
部分支持 Partial
Disabled
Does not support the subtree 选项。
Disabled This feature is behind the Web 动画 preference and the CSS Animations via Web Animations preference.
WebView Android No Chrome Android 79
Disabled
79
Disabled
Disabled From version 79: this feature is behind the Experimental Web Platform Features preference. To change preferences in Chrome, visit chrome://flags.
不支持 67 — 79
Disabled
Does not support the subtree 选项。
Disabled From version 67 until version 79 (exclusive): this feature is behind the Experimental Web Platform Features preference. To change preferences in Chrome, visit chrome://flags.
不支持 44 — 67
Disabled
Does not automatically flush pending style changes and does not support the subtree 选项。
Disabled From version 44 until version 67 (exclusive): this feature is behind the Experimental Web Platform Features preference. To change preferences in Chrome, visit chrome://flags.
不支持 38 — 44
Alternate Name Disabled
Does not automatically flush pending style changes and does not support the subtree 选项。
Alternate Name Uses the non-standard name: getAnimationPlayers
Disabled From version 38 until version 44 (exclusive): this feature is behind the Experimental Web Platform Features preference. To change preferences in Chrome, visit chrome://flags.
Firefox Android 63
Disabled
63
Disabled
Disabled From version 63: this feature is behind the dom.animations-api.getAnimations.enabled preference. To change preferences in Firefox, visit about:config.
不支持 48 — 63
Disabled
Disabled From version 48 until version 63 (exclusive): this feature is behind the dom.animations-api.core.enabled preference. To change preferences in Firefox, visit about:config.
不支持 40 — 48
Disabled
Does not support the subtree 选项。
Disabled From version 40 until version 48 (exclusive): this feature is behind the dom.animations-api.core.enabled preference. To change preferences in Firefox, visit about:config.
不支持 35 — 40
Alternate Name Disabled
Does not support the subtree 选项。
Alternate Name Uses the non-standard name: getAnimationPlayers
Disabled From version 35 until version 40 (exclusive): this feature is behind the dom.animations-api.core.enabled preference. To change preferences in Firefox, visit about:config.
不支持 33 — 35
Alternate Name Disabled
Does not automatically flush pending style changes and does not support the subtree 选项。
Alternate Name Uses the non-standard name: getAnimationPlayers
Disabled From version 33 until version 35 (exclusive): this feature is behind the dom.animations-api.core.enabled preference. To change preferences in Firefox, visit about:config.
Opera Android 部分支持 48
Disabled
部分支持 48
Disabled
Does not support the subtree 选项。
Disabled From version 48: this feature is behind the Experimental Web Platform Features preference.
不支持 32 — 48
Disabled
Does not automatically flush pending style changes and does not support the subtree 选项。
Disabled From version 32 until version 48 (exclusive): this feature is behind the Experimental Web Platform Features preference.
不支持 25 — 32
Alternate Name Disabled
Does not automatically flush pending style changes and does not support the subtree 选项。
Alternate Name Uses the non-standard name: getAnimationPlayers
Disabled From version 25 until version 32 (exclusive): this feature is behind the Experimental Web Platform Features preference.
Safari iOS 部分支持 Partial
Disabled
部分支持 Partial
Disabled
Does not support the subtree 选项。
Disabled This feature is behind the Web 动画 preference and the CSS Animations via Web Animations preference.
Samsung Internet Android No
getAttribute Chrome 1 Edge 12 Firefox 23 IE 8 Opera 8 Safari 1.3 WebView Android 1 Chrome Android 18 Firefox Android 23 Opera Android 10.1 Safari iOS 1 Samsung Internet Android 1.0
getAttributeNames Chrome 61 Edge 18 Firefox 45 IE No Opera 48 Safari 10 WebView Android 61 Chrome Android 61 Firefox Android 45 Opera Android 45 Safari iOS Yes Samsung Internet Android 8.0
getAttributeNode Chrome Yes Edge 12 Firefox Yes IE ? Opera Yes Safari 6 WebView Android Yes Chrome Android Yes Firefox Android Yes Opera Android Yes Safari iOS Yes Samsung Internet Android Yes
getAttributeNodeNS Chrome Yes Edge 12 Firefox Yes IE ? Opera Yes Safari 6 WebView Android Yes Chrome Android Yes Firefox Android Yes Opera Android Yes Safari iOS Yes Samsung Internet Android Yes
getAttributeNS Chrome Yes Edge 12 Firefox Yes
Yes
Starting in Firefox 13, null is always returned instead of the empty string, as per the DOM4 specification. Previously, there were cases in which an empty string could be returned.
IE Yes Opera Yes Safari 6 WebView Android Yes Chrome Android Yes Firefox Android Yes Opera Android Yes Safari iOS Yes Samsung Internet Android Yes
getBoundingClientRect Chrome 2 Edge 12 Firefox 3 IE 4 Opera 9.5 Safari 6 WebView Android ≤37 Chrome Android 18 Firefox Android 4 Opera Android 10.1 Safari iOS 4
4
Safari for iOS will modify the effective viewport based on the user zoom. This results in incorrect values whenever the user has zoomed.
Samsung Internet Android 1.0
getClientRects Chrome 2 Edge 12 Firefox 3 IE 8 Opera 9.5 Safari 6 WebView Android 1 Chrome Android 18 Firefox Android 4 Opera Android 10.1 Safari iOS 6 Samsung Internet Android 1.0
getElementsByClassName Chrome 1 Edge 18
18
不支持 12 — 18
This function is implemented in the HTMLElement API, meaning non-HTML elements (like SVG elements) cannot use this function.
Firefox 3
3
Prior to Firefox 19, this method was returning a NodeList ; it was then changed to reflect the change in the spec.
IE 9
9
This function is implemented in the HTMLElement API, meaning non-HTML elements (like SVG elements) cannot use this function.
Opera 9.5 Safari 6 WebView Android 1 Chrome Android 18 Firefox Android 4 Opera Android 10.1 Safari iOS 6 Samsung Internet Android 1.0
getElementsByTagName Chrome 1
1
Initially, this method was returning a NodeList ; it was then changed to reflect the spec change.
Edge 12 Firefox 1
1
Prior to Firefox 19, this method was returning a NodeList ; it was then changed to reflect the change in the spec.
IE 5.5 Opera 8
8
Initially, this method was returning a NodeList ; it was then changed to reflect the spec change.
Safari 6
6
Initially, this method was returning a NodeList ; it was then changed to reflect the spec change.
WebView Android 1
1
Initially, this method was returning a NodeList ; it was then changed to reflect the spec change.
Chrome Android 18
18
Initially, this method was returning a NodeList ; it was then changed to reflect the spec change.
Firefox Android 4
4
Prior to Firefox 19, this method was returning a NodeList ; it was then changed to reflect the change in the spec.
Opera Android 10.1 Safari iOS 6
6
Initially, this method was returning a NodeList ; it was then changed to reflect the spec change.
Samsung Internet Android 1.0
1.0
Initially, this method was returning a NodeList ; it was then changed to reflect the spec change.
getElementsByTagNameNS Chrome 1
1
Initially, this method was returning a NodeList ; it was then changed to reflect the spec change.
Edge 12 Firefox Yes
Yes
The behavior of element.getElementsByTagNameNS changed between Firefox 3.5 and Firefox 3.6. In Firefox 3.5 and before, this function would automatically case-fold any queries so that a search for "foo" would match "Foo" or "foo". In Firefox 3.6 and later this function is now case-sensitive so that a query for "foo" will only match "foo" and not "Foo". For more background on this, please see the comment from Henri Sivonen about the change . You can also look at the relevant part of the standard, which states which parts of the API are case-sensitive and which parts aren't.
Prior to Firefox 19, this method was returning a NodeList ; it was then changed to reflects the spec change.
IE 5.5 Opera Yes
Yes
Initially, this method was returning a NodeList ; it was then changed to reflect the spec change.
Safari 6
6
Initially, this method was returning a NodeList ; it was then changed to reflect the spec change.
WebView Android Yes Chrome Android Yes Firefox Android Yes
Yes
The behavior of element.getElementsByTagNameNS changed between Firefox 3.5 and Firefox 3.6. In Firefox 3.5 and before, this function would automatically case-fold any queries so that a search for "foo" would match "Foo" or "foo". In Firefox 3.6 and later this function is now case-sensitive so that a query for "foo" will only match "foo" and not "Foo". For more background on this, please see the comment from Henri Sivonen about the change . You can also look at the relevant part of the standard, which states which parts of the API are case-sensitive and which parts aren't.
Prior to Firefox 19, this method was returning a NodeList ; it was then changed to reflects the spec change.
Opera Android Yes Safari iOS Yes Samsung Internet Android Yes
hasAttribute Chrome 1 Edge 12 Firefox 1 IE 8 Opera 8 Safari 6 WebView Android 1 Chrome Android 18 Firefox Android 4 Opera Android 10.1 Safari iOS 6 Samsung Internet Android 1.0
hasAttributeNS Chrome Yes Edge 12 Firefox Yes IE ? Opera Yes Safari 6 WebView Android Yes Chrome Android Yes Firefox Android Yes Opera Android Yes Safari iOS Yes Samsung Internet Android Yes
hasAttributes Chrome Yes Edge 16 Firefox Yes
Yes
[1] Before Firefox 35, it was implemented on the Node 接口。
IE 9 Opera Yes Safari 6 WebView Android Yes Chrome Android Yes Firefox Android Yes Opera Android Yes Safari iOS Yes Samsung Internet Android Yes
hasPointerCapture Chrome 55 Edge ≤79 Firefox 59
59
41
Disabled
Disabled From version 41: this feature is behind the dom.w3c_pointer_events.enabled preference (needs to be set to true ). To change preferences in Firefox, visit about:config.
IE ? Opera 42 Safari 13 WebView Android 55 Chrome Android 55 Firefox Android No
不支持 No
41
Disabled
Disabled From version 41: this feature is behind the dom.w3c_pointer_events.enabled preference (needs to be set to true ). To change preferences in Firefox, visit about:config.
Opera Android 42 Safari iOS 13 Samsung Internet Android 6.0
id Chrome 42 Edge 12 Firefox Yes IE Yes Opera Yes Safari 6 WebView Android 42 Chrome Android 42 Firefox Android Yes Opera Android Yes Safari iOS Yes Samsung Internet Android 4.0
innerHTML Chrome 33
33
This API was previously available on the Node API.
Edge 12 Firefox 1 IE 4 Opera 8 Safari 9 WebView Android 4.4
4.4
This API was previously available on the Node API.
Chrome Android 33
33
This API was previously available on the Node API.
Firefox Android 4 Opera Android 10.1 Safari iOS 9 Samsung Internet Android 2.0
2.0
This API was previously available on the Node API.
insertAdjacentElement Chrome 1 Edge 18
18
不支持 12 — 18
This function is implemented in the HTMLElement API, meaning non-HTML elements (like SVG elements) cannot use this function.
Firefox 48 IE 8
8
This function is implemented in the HTMLElement API, meaning non-HTML elements (like SVG elements) cannot use this function.
Opera 8 Safari 10 WebView Android 1 Chrome Android 18 Firefox Android 48 Opera Android 10.1 Safari iOS 10 Samsung Internet Android 1.0
insertAdjacentHTML Chrome 1 Edge 18
18
不支持 12 — 18
This function is implemented in the HTMLElement API, meaning non-HTML elements (like SVG elements) cannot use this function.
Firefox 8 IE 4
4
Before Internet Explorer 10, throws an "Invalid target element for this operation." error when called on a <table> , <tbody> , <thead> ,或 <tr> 元素。
This function is implemented in the HTMLElement API, meaning non-HTML elements (like SVG elements) cannot use this function.
Opera 8 Safari 10 WebView Android 1 Chrome Android 18 Firefox Android 8 Opera Android 10.1 Safari iOS 4 Samsung Internet Android 1.0
insertAdjacentText Chrome 1 Edge 18
18
12
This function is implemented in the HTMLElement API, meaning non-HTML elements (like SVG elements) cannot use this function.
Firefox 48 IE Yes
Yes
This function is implemented in the HTMLElement API, meaning non-HTML elements (like SVG elements) cannot use this function.
Opera Yes Safari 10 WebView Android 2.3 Chrome Android 18 Firefox Android 48 Opera Android Yes Safari iOS Yes Samsung Internet Android 1.0
keydown event Chrome Yes Edge ≤18 Firefox Yes IE ? Opera ? Safari ? WebView Android Yes Chrome Android Yes Firefox Android Yes Opera Android ? Safari iOS ? Samsung Internet Android Yes
keypress event
弃用
Chrome Yes
Yes
Chrome does not fire the keypress event for known keyboard shortcuts . Which keyboard shortcuts are known depends on the user's system. Use the keydown event to implement keyboard shortcuts.
Edge ≤18 Firefox Yes
Yes
As of Firefox 65, the keypress event is no longer fired for non-printable keys , except for the Enter key, and the Shift + Enter and Ctrl + Enter key combinations (these were kept for cross-browser compatibility purposes).
IE ? Opera ? Safari ? WebView Android Yes
Yes
Chrome does not fire the keypress event for known keyboard shortcuts . Which keyboard shortcuts are known depends on the user's system. Use the keydown event to implement keyboard shortcuts.
Chrome Android Yes
Yes
Chrome does not fire the keypress event for known keyboard shortcuts . Which keyboard shortcuts are known depends on the user's system. Use the keydown event to implement keyboard shortcuts.
Firefox Android Yes
Yes
As of Firefox 65, the keypress event is no longer fired for non-printable keys , except for the Enter key, and the Shift + Enter and Ctrl + Enter key combinations (these were kept for cross-browser compatibility purposes).
Opera Android ? Safari iOS ? Samsung Internet Android Yes
Yes
Samsung Internet does not fire the keypress event for known keyboard shortcuts . Which keyboard shortcuts are known depends on the user's system. Use the keydown event to implement keyboard shortcuts.
keyup event Chrome Yes Edge ≤18 Firefox Yes IE ? Opera ? Safari ? WebView Android Yes Chrome Android Yes Firefox Android Yes Opera Android ? Safari iOS ? Samsung Internet Android Yes
localName Chrome 31
31
This API was previously available on the Node API.
Edge 17 Firefox 48
48
This API was previously available on the Node API.
IE 9 Opera Yes Safari 10 WebView Android Yes
Yes
This API was previously available on the Node API.
Chrome Android 31
31
This API was previously available on the Node API.
Firefox Android 48
48
This API was previously available on the Node API.
Opera Android Yes Safari iOS Yes Samsung Internet Android 2.0
2.0
This API was previously available on the Node API.
matches Chrome 33
33
4
Alternate Name
Alternate Name Uses the non-standard name: webkitMatchesSelector
Edge ≤18
≤18
≤18
Alternate Name
Alternate Name Uses the non-standard name: webkitMatchesSelector
12
Alternate Name
Alternate Name Uses the non-standard name: msMatchesSelector
Firefox 34
34
44
Alternate Name
Alternate Name Uses the non-standard name: webkitMatchesSelector
3.6
Alternate Name
Prior to Firefox 4, invalid selector strings caused false to be returned instead of throwing an exception.
bug 1119718 for removal.
Alternate Name Uses the non-standard name: mozMatchesSelector
IE 9
Alternate Name
9
Alternate Name
Alternate Name Uses the non-standard name: msMatchesSelector
Opera 21
21
15
Alternate Name
Alternate Name Uses the non-standard name: webkitMatchesSelector
不支持 11.5 — 15
Alternate Name
Alternate Name Uses the non-standard name: oMatchesSelector
Safari 7
7
5
Alternate Name
Alternate Name Uses the non-standard name: webkitMatchesSelector
WebView Android 4.4
4.4
≤37
Alternate Name
Alternate Name Uses the non-standard name: webkitMatchesSelector
Chrome Android 33
33
18
Alternate Name
Alternate Name Uses the non-standard name: webkitMatchesSelector
Firefox Android 34
34
44
Alternate Name
Alternate Name Uses the non-standard name: webkitMatchesSelector
4
Alternate Name
bug 1119718 for removal.
Alternate Name Uses the non-standard name: mozMatchesSelector
Opera Android 21
21
14
Alternate Name
Alternate Name Uses the non-standard name: webkitMatchesSelector
不支持 11.5 — 14
Alternate Name
Alternate Name Uses the non-standard name: oMatchesSelector
Safari iOS 8
8
4.2
Alternate Name
Alternate Name Uses the non-standard name: webkitMatchesSelector
Samsung Internet Android 2.0
2.0
1.0
Alternate Name
Alternate Name Uses the non-standard name: webkitMatchesSelector
mousedown event Chrome 2 Edge 12 Firefox 6 IE 9 Opera 11.6 Safari 4 WebView Android 1 Chrome Android 18 Firefox Android 6 Opera Android 12.1 Safari iOS 3.2 Samsung Internet Android 1.0
mouseenter event Chrome 30 Edge 12 Firefox 10 IE 5.5 Opera 17 Safari 6.1 WebView Android ≤37 Chrome Android 30 Firefox Android 10 Opera Android 18 Safari iOS 6.1 Samsung Internet Android 2.0
mouseleave event Chrome 30 Edge 12 Firefox 10 IE 5.5 Opera 17 Safari 6.1 WebView Android ≤37 Chrome Android 30 Firefox Android 10 Opera Android 18 Safari iOS 6.1 Samsung Internet Android 2.0
mousemove event Chrome 2 Edge 12 Firefox 6 IE 9 Opera 11.6 Safari 4 WebView Android ≤37 Chrome Android 18 Firefox Android 6 Opera Android 12.1 Safari iOS 3.2 Samsung Internet Android 1.0
mouseout event Chrome Yes Edge 12 Firefox Yes IE Yes Opera Yes Safari Yes WebView Android Yes Chrome Android Yes Firefox Android Yes Opera Android Yes Safari iOS Yes Samsung Internet Android Yes
mouseover event Chrome 2 Edge 12 Firefox 6 IE 9 Opera 9.5 Safari 4 WebView Android ≤37 Chrome Android 18 Firefox Android 6 Opera Android 10.1 Safari iOS 3.2 Samsung Internet Android 1.0
mouseup event Chrome 2 Edge 12 Firefox 6 IE 9 Opera 11.6 Safari 4 WebView Android ≤37 Chrome Android 18 Firefox Android 6 Opera Android 12.1 Safari iOS 3.2 Samsung Internet Android 1.0
mousewheel event
弃用 非标
Chrome 31 Edge ≤79 Firefox No IE ? Opera ? Safari ? WebView Android ? Chrome Android ? Firefox Android No Opera Android ? Safari iOS ? Samsung Internet Android ?
msContentZoom event
非标
Chrome No Edge 12 — 79 Firefox No IE Yes Opera No Safari No WebView Android No Chrome Android No Firefox Android No Opera Android No Safari iOS No Samsung Internet Android No
name Chrome No Edge No Firefox ? IE ? Opera No Safari ? WebView Android No Chrome Android No Firefox Android ? Opera Android No Safari iOS ? Samsung Internet Android No
namespaceURI Chrome 31
31
This API was previously available on the Node API.
Edge 17 Firefox 48
48
This API was previously available on the Node API.
IE ? Opera Yes
Yes
This API was previously available on the Node API.
Safari 10 WebView Android Yes
Yes
This API was previously available on the Node API.
Chrome Android 31
31
This API was previously available on the Node API.
Firefox Android Yes Opera Android Yes Safari iOS Yes Samsung Internet Android 2.0
2.0
This API was previously available on the Node API.
onfullscreenchange Chrome 57 Edge ≤79 Firefox 64
64
不支持 10 — 65
Alternate Name
Alternate Name Uses the non-standard name: onmozfullscreenchange
IE ? Opera Yes Safari ? WebView Android 57 Chrome Android 57 Firefox Android 64
64
不支持 10 — 65
Alternate Name
Alternate Name Uses the non-standard name: onmozfullscreenchange
Opera Android Yes Safari iOS ? Samsung Internet Android 7.0
onfullscreenerror Chrome 57 Edge ≤79 Firefox 64
64
不支持 10 — 65
Alternate Name
Alternate Name Uses the non-standard name: onmozfullscreenerror
IE ? Opera Yes Safari ? WebView Android 57 Chrome Android 57 Firefox Android 64
64
不支持 10 — 65
Alternate Name
Alternate Name Uses the non-standard name: onmozfullscreenerror
Opera Android Yes Safari iOS ? Samsung Internet Android 7.0
openOrClosedShadowRoot
非标
Chrome No Edge No Firefox 63
63
Available only to WebExtensions .
IE No Opera No Safari No WebView Android No Chrome Android No Firefox Android 63
63
Available only to WebExtensions .
Opera Android No Safari iOS No Samsung Internet Android No
outerHTML Chrome 33
33
This API was previously available on the Node API.
Edge 12 Firefox 11 IE 4 Opera 8 Safari 9 WebView Android 4.4
4.4
This API was previously available on the Node API.
Chrome Android 33
33
This API was previously available on the Node API.
Firefox Android 14 Opera Android 10.1 Safari iOS 9 Samsung Internet Android 2.0
2.0
This API was previously available on the Node API.
overflow event
非标
Chrome No Edge No Firefox Yes IE No Opera No Safari No WebView Android No Chrome Android No Firefox Android Yes Opera Android No Safari iOS No Samsung Internet Android No
part Chrome Yes Edge 79 Firefox 71
Disabled
71
Disabled
Disabled From version 71: this feature is behind the layout.css.shadow-parts.enabled preference (needs to be set to true ). To change preferences in Firefox, visit about:config.
IE No Opera Yes Safari 13.1 WebView Android Yes Chrome Android Yes Firefox Android No Opera Android ? Safari iOS 13.4 Samsung Internet Android Yes
paste event Chrome 58 Edge 12 Firefox 22 IE 11 Opera 45 Safari 5 WebView Android 58 Chrome Android 58 Firefox Android 22 Opera Android 43 Safari iOS 4.2 Samsung Internet Android 7.0
prefix Chrome 31
31
This API was previously available on the Node API.
Edge 13 Firefox 48
48
This API was previously available on the Node API.
IE ? Opera Yes Safari 10 WebView Android Yes Chrome Android 31
31
This API was previously available on the Node API.
Firefox Android 48
48
This API was previously available on the Node API.
Opera Android Yes Safari iOS Yes Samsung Internet Android 2.0
2.0
This API was previously available on the Node API.
querySelector Chrome 1 Edge 12 Firefox 3.5 IE 9
9
部分支持 8
querySelector() is supported, but only for CSS 2.1 selectors.
Opera 10 Safari 3.1 WebView Android 1 Chrome Android 18 Firefox Android 4 Opera Android 10.1 Safari iOS 2 Samsung Internet Android 1.0
querySelectorAll Chrome 1 Edge 12 Firefox 3.5 IE 9
9
部分支持 8
querySelectorAll() is supported, but only for CSS 2.1 selectors.
Opera 10 Safari 3.1 WebView Android 1 Chrome Android 18 Firefox Android 4 Opera Android 10.1 Safari iOS 2 Samsung Internet Android 1.0
releasePointerCapture Chrome 55 Edge 12 Firefox 59
59
41
Disabled
Disabled From version 41: this feature is behind the dom.w3c_pointer_events.enabled preference (needs to be set to true ). To change preferences in Firefox, visit about:config.
IE 11
11
10
Prefixed
Prefixed Implemented with the vendor prefix: ms
Opera 42 Safari 13 WebView Android 55 Chrome Android 55 Firefox Android No
不支持 No
41
Disabled
Disabled From version 41: this feature is behind the dom.w3c_pointer_events.enabled preference (needs to be set to true ). To change preferences in Firefox, visit about:config.
Opera Android 42 Safari iOS 13 Samsung Internet Android 6.0
removeAttribute Chrome 1 Edge 12
12
This function doesn't respect boolean attributes' default values. See bug 12087679 .
Firefox 1 IE 8 Opera 8 Safari 3 WebView Android 1 Chrome Android 18 Firefox Android 4 Opera Android 10.1 Safari iOS 1 Samsung Internet Android 1.0
removeAttributeNode Chrome Yes Edge 12 Firefox Yes IE ? Opera Yes Safari 6 WebView Android Yes Chrome Android Yes Firefox Android Yes Opera Android Yes Safari iOS Yes Samsung Internet Android Yes
removeAttributeNS Chrome Yes Edge 12 Firefox Yes IE ? Opera Yes Safari 6 WebView Android Yes Chrome Android Yes Firefox Android Yes Opera Android Yes Safari iOS Yes Samsung Internet Android Yes
requestFullscreen Chrome 69
69
15
Prefixed
Prefixed Implemented with the vendor prefix: webkit
Edge 79
79
79
Prefixed
Prefixed Implemented with the vendor prefix: webkit
不支持 12 — 14
Prefixed
Prefixed Implemented with the vendor prefix: webkit
Firefox 64
64
不支持 47 — 65
Disabled
Disabled From version 47 until version 65 (exclusive): this feature is behind the full-screen-api.unprefix.enabled preference (needs to be set to true ). To change preferences in Firefox, visit about:config.
不支持 9 — 65
Alternate Name
Before Firefox 44, Firefox incorrectly allowed elements inside a <frame> or <object> element to request, and to be granted, fullscreen. In Firefox 44 and onwards this has been fixed: only elements in the top-level document or in an <iframe> element with the allowfullscreen attribute can be displayed fullscreen.
Alternate Name Uses the non-standard name: mozRequestFullScreen
IE 11
Prefixed
11
Prefixed
Prefixed Implemented with the vendor prefix: ms
Opera 58
58
15
Prefixed
Prefixed Implemented with the vendor prefix: webkit
不支持 12 — 15
Prefixed
Prefixed Implemented with the vendor prefix: o
Safari 6
Prefixed
6
Prefixed
Prefixed Implemented with the vendor prefix: webkit
WebView Android 69
69
≤37
Prefixed
Prefixed Implemented with the vendor prefix: webkit
Chrome Android 69
69
18
Prefixed
Prefixed Implemented with the vendor prefix: webkit
Firefox Android 64
64
不支持 47 — 65
Disabled
Disabled From version 47 until version 65 (exclusive): this feature is behind the full-screen-api.unprefix.enabled preference (needs to be set to true ). To change preferences in Firefox, visit about:config.
不支持 9 — 65
Alternate Name
Before Firefox 44, Firefox incorrectly allowed elements inside a <frame> or an <object> to request, and to be granted, fullscreen. In Firefox 44 and onwards this has been fixed: only elements in the top-level document or in an <iframe> with the allowfullscreen attribute can be displayed fullscreen.
Alternate Name Uses the non-standard name: mozRequestFullScreen
Opera Android 50
50
14
Prefixed
Prefixed Implemented with the vendor prefix: webkit
不支持 12 — 14
Prefixed
Prefixed Implemented with the vendor prefix: o
Safari iOS 6
Prefixed
6
Prefixed
Prefixed Implemented with the vendor prefix: webkit
Only available on iPad, not on iPhone. Shows an overlay button which can not be disabled.
Samsung Internet Android 10.0
10.0
1.0
Prefixed
Prefixed Implemented with the vendor prefix: webkit
requestPointerLock Chrome Yes
Yes
Yes
Prefixed
Prefixed Implemented with the vendor prefix: webkit
Edge 13 Firefox 50
50
Yes
Prefixed
Prefixed Implemented with the vendor prefix: moz
IE ? Opera Yes Safari 10 WebView Android Yes
Yes
Yes
Prefixed
Prefixed Implemented with the vendor prefix: webkit
Chrome Android Yes
Yes
Yes
Prefixed
Prefixed Implemented with the vendor prefix: webkit
Firefox Android Yes Opera Android Yes Safari iOS ? Samsung Internet Android Yes
Yes
Yes
Prefixed
Prefixed Implemented with the vendor prefix: webkit
runtimeStyle
非标
Chrome No Edge No Firefox No IE 6 Opera No Safari No WebView Android No Chrome Android No Firefox Android No Opera Android No Safari iOS No Samsung Internet Android No
scroll Chrome 45 Edge 79 Firefox 36 IE No Opera 32 Safari 10 WebView Android 45 Chrome Android 45 Firefox Android 36 Opera Android 32 Safari iOS No Samsung Internet Android 5.0
scroll event Chrome Yes Edge ≤18 Firefox Yes IE ? Opera ? Safari ? WebView Android Yes Chrome Android Yes Firefox Android Yes Opera Android ? Safari iOS ? Samsung Internet Android Yes
scrollBy Chrome 45 Edge 79 Firefox Yes IE No Opera 32 Safari 10 WebView Android 45 Chrome Android 45 Firefox Android Yes Opera Android 32 Safari iOS No Samsung Internet Android 5.0
scrollHeight Chrome 4 Edge 12 Firefox 21
21
不支持 3 — 21
In Firefox versions prior to 21, when an element's content does not generate a vertical scrollbar, then its scrollHeight property is equal to its clientHeight property. This can mean either the content is too short to require a scrollbar or that the element has a CSS style overflow value of visible (non-scrollable).
IE 5
5
In Internet Explorer 5 through 7, if padding is set, the value of scrollHeight is equal to the sum of the top and bottom padding. This behavior was fixed in Internet Explorer 8.
Opera 8 Safari 6 WebView Android ≤37 Chrome Android 18 Firefox Android 21
21
不支持 4 — 21
In Firefox versions prior to 21, when an element's content does not generate a vertical scrollbar, then its scrollHeight property is equal to its clientHeight property. This can mean either the content is too short to require a scrollbar or that the element has a CSS style overflow value of visible (non-scrollable).
Opera Android 10.1 Safari iOS 6 Samsung Internet Android 1.0
scrollIntoView
Chrome 29 Edge 18
18
The only parameter supported is alignToTop .
不支持 12 — 18
This function is implemented in the HTMLElement API, meaning non-HTML elements (like SVG elements) cannot use this function.
No support for smooth behavior.
Firefox 1 IE 8
8
This function is implemented in the HTMLElement API, meaning non-HTML elements (like SVG elements) cannot use this function.
No support for smooth behavior or center 选项。
Opera 38 Safari 6
6
No support for smooth behavior or center 选项。
WebView Android ≤37 Chrome Android 29 Firefox Android 4 Opera Android 41 Safari iOS 5
5
No support for smooth behavior or center 选项。
Samsung Internet Android 2.0
scrollIntoViewIfNeeded
非标
Chrome 1 Edge 79 Firefox No IE No Opera 15 Safari 3 WebView Android 1 Chrome Android 18 Firefox Android No Opera Android 14 Safari iOS 1 Samsung Internet Android 1.0
scrollLeft Chrome 43
43
For right-to-left elements, this property uses 0-100 (most left to most right) instead of negative values. See bug 721759 .
Edge 12
12
From Edge 79, for right-to-left elements, this property uses 0-100 (most left to most right) instead of negative values. See bug 721759 .
Before Edge 79, for right-to-left elements, this property uses 100-0 (most left to most right) instead of negative values.
Firefox 1 IE 8
8
For right-to-left elements, this property uses 100-0 (most left to most right) instead of negative values.
Opera 8 Safari 6 WebView Android 43
43
For right-to-left elements, this property uses 0-100 (most left to most right) instead of negative values. See bug 721759 .
Chrome Android 43
43
For right-to-left elements, this property uses 0-100 (most left to most right) instead of negative values. See bug 721759 .
Firefox Android 4 Opera Android 10.1 Safari iOS 6 Samsung Internet Android 4.0
scrollLeftMax
非标
Chrome No Edge No Firefox 16 IE No Opera No Safari No WebView Android No Chrome Android No Firefox Android 16 Opera Android No Safari iOS No Samsung Internet Android No
scrollTo Chrome 45 Edge 79 Firefox 36 IE No Opera 32 Safari 10 WebView Android 45 Chrome Android 45 Firefox Android 36 Opera Android 32 Safari iOS No Samsung Internet Android 5.0
scrollTop Chrome 43 Edge 12 Firefox 1 IE 8 Opera 8 Safari 6 WebView Android 43 Chrome Android 43 Firefox Android 4 Opera Android 10.1 Safari iOS 6 Samsung Internet Android 4.0
scrollTopMax
非标
Chrome No Edge No Firefox 16 IE No Opera No Safari No WebView Android No Chrome Android No Firefox Android 16 Opera Android No Safari iOS No Samsung Internet Android No
scrollWidth Chrome 43 Edge 12 Firefox Yes IE 5
5
In Internet Explorer 5 through 7, if padding is set, the value of scrollWidth is equal to the sum of the left and right padding. This behavior was fixed in Internet Explorer 8.
Opera Yes Safari 6 WebView Android Yes Chrome Android 43 Firefox Android Yes Opera Android Yes Safari iOS Yes Samsung Internet Android 4.0
select event Chrome Yes Edge ≤18 Firefox Yes IE ? Opera ? Safari ? WebView Android Yes Chrome Android Yes Firefox Android Yes Opera Android ? Safari iOS ? Samsung Internet Android Yes
setAttribute Chrome 1 Edge 12 Firefox 1 IE 5
5
In Internet Explorer 7 and earlier, setAttribute doesn't set styles and removes events when you try to set them.
Opera 8 Safari 3 WebView Android 1 Chrome Android 18 Firefox Android 4 Opera Android 10.1 Safari iOS 1 Samsung Internet Android 1.0
setAttributeNode Chrome Yes Edge 12 Firefox Yes IE ? Opera Yes Safari 6 WebView Android Yes Chrome Android Yes Firefox Android Yes Opera Android Yes Safari iOS Yes Samsung Internet Android Yes
setAttributeNodeNS Chrome Yes Edge 12
12
返回 ClientRectList with ClientRect objects (which do not contain x and y properties) instead of DOMRect 对象。
Firefox Yes IE Yes
Yes
返回 ClientRectList with ClientRect objects (which do not contain x and y properties) instead of DOMRect 对象。
Opera Yes Safari 6 WebView Android Yes Chrome Android Yes Firefox Android Yes Opera Android Yes Safari iOS Yes Samsung Internet Android Yes
setAttributeNS Chrome Yes Edge 12 Firefox Yes IE ? Opera Yes Safari 6 WebView Android Yes Chrome Android Yes Firefox Android Yes Opera Android Yes Safari iOS Yes Samsung Internet Android Yes
setCapture
弃用 非标
Chrome No Edge 12 — 79
不支持 12 — 79
retargetToElement parameter to Element.setCapture() was introduced in Edge 5.5.
Firefox Yes IE 5
5
retargetToElement parameter to Element.setCapture() was introduced in Internet Explorer 5.5.
Opera No Safari ? WebView Android No Chrome Android No Firefox Android ? Opera Android No Safari iOS ? Samsung Internet Android No
setPointerCapture Chrome 55 Edge 12 Firefox 59
59
41
Disabled
Disabled From version 41: this feature is behind the dom.w3c_pointer_events.enabled preference (needs to be set to true ). To change preferences in Firefox, visit about:config.
IE 11
11
10
Prefixed
Prefixed Implemented with the vendor prefix: ms
Opera 42 Safari 13 WebView Android 55 Chrome Android 55 Firefox Android No
不支持 No
41
Disabled
Disabled From version 41: this feature is behind the dom.w3c_pointer_events.enabled preference (needs to be set to true ). To change preferences in Firefox, visit about:config.
Opera Android 42 Safari iOS 13 Samsung Internet Android 6.0
shadowRoot Chrome 43 Edge 79 Firefox 63
63
不支持 59 — 63
Disabled
Disabled From version 59 until version 63 (exclusive): this feature is behind the dom.webcomponents.shadowdom.enabled preference (needs to be set to true ). To change preferences in Firefox, visit about:config.
IE No Opera 40 Safari 10 WebView Android 43 Chrome Android 43 Firefox Android 63
63
不支持 59 — 63
Disabled
Disabled From version 59 until version 63 (exclusive): this feature is behind the dom.webcomponents.shadowdom.enabled preference (needs to be set to true ). To change preferences in Firefox, visit about:config.
Opera Android 41 Safari iOS Yes Samsung Internet Android 4.0
show event
弃用
Chrome No Edge No Firefox Yes IE ? Opera ? Safari ? WebView Android No Chrome Android No Firefox Android Yes Opera Android ? Safari iOS ? Samsung Internet Android No
slot Chrome 53 Edge ≤79 Firefox 63 IE ? Opera Yes Safari 10 WebView Android 53 Chrome Android 53 Firefox Android 63 Opera Android Yes Safari iOS Yes Samsung Internet Android 6.0
tabStop
弃用 非标
Chrome 43 Edge ≤79 Firefox ? IE ? Opera ? Safari ? WebView Android 43 Chrome Android 43 Firefox Android ? Opera Android ? Safari iOS ? Samsung Internet Android 4.0
tagName Chrome 43 Edge 12 Firefox 1 IE 8 Opera 8 Safari 6 WebView Android 43 Chrome Android 43 Firefox Android 4 Opera Android 10.1 Safari iOS 6 Samsung Internet Android 4.0
toggleAttribute Chrome 69 Edge 18 Firefox 63 IE No Opera 56 Safari 12 WebView Android 69 Chrome Android 69 Firefox Android 63 Opera Android 48 Safari iOS Yes Samsung Internet Android 10.0
touchcancel event Chrome 22 Edge 12 Firefox 52 IE No Opera No Safari No WebView Android Yes Chrome Android 25 Firefox Android 6 Opera Android Yes Safari iOS Yes Samsung Internet Android 1.5
touchend event Chrome 22 Edge 12 Firefox 52 IE No Opera No Safari No WebView Android Yes Chrome Android 25 Firefox Android 6 Opera Android Yes Safari iOS Yes Samsung Internet Android 1.5
touchmove event Chrome 22 Edge 12 Firefox 52 IE No Opera No Safari No WebView Android Yes Chrome Android 25 Firefox Android 6 Opera Android Yes Safari iOS Yes Samsung Internet Android 1.5
touchstart event Chrome 22 Edge 12 Firefox 52 IE No Opera No Safari No WebView Android Yes Chrome Android 25 Firefox Android 6 Opera Android Yes Safari iOS Yes Samsung Internet Android 1.5
underflow event
非标
Chrome No Edge No Firefox Yes IE No Opera No Safari No WebView Android No Chrome Android No Firefox Android Yes Opera Android No Safari iOS No Samsung Internet Android No
webkitmouseforcechanged event
非标
Chrome No Edge No Firefox No IE No Opera No Safari Yes WebView Android No Chrome Android No Firefox Android No Opera Android No Safari iOS Yes Samsung Internet Android No
webkitmouseforcedown event
非标
Chrome No Edge No Firefox No IE No Opera No Safari Yes WebView Android No Chrome Android No Firefox Android No Opera Android No Safari iOS Yes Samsung Internet Android No
webkitmouseforceup event
非标
Chrome No Edge No Firefox No IE No Opera No Safari Yes WebView Android No Chrome Android No Firefox Android No Opera Android No Safari iOS Yes Samsung Internet Android No
webkitmouseforcewillbegin event
非标
Chrome No Edge No Firefox No IE No Opera No Safari Yes WebView Android No Chrome Android No Firefox Android No Opera Android No Safari iOS Yes Samsung Internet Android No
wheel event Chrome 61 Edge 12 Firefox 17 IE 9
9
Internet Explorer only exposes the wheel event via addEventListener ; there is no onwheel attribute on DOM objects. See IE bug 782835 .
Opera 48 Safari 7 WebView Android 61 Chrome Android 61 Firefox Android 17 Opera Android 45 Safari iOS 7 Samsung Internet Android 8.0

图例

完整支持
完整支持
部分支持
部分支持
不支持
不支持
兼容性未知
兼容性未知
实验。期望将来行为有所改变。
实验。期望将来行为有所改变。
非标。预期跨浏览器支持较差。
非标。预期跨浏览器支持较差。
弃用。不要用于新网站。
弃用。不要用于新网站。
见实现注意事项。
用户必须明确启用此特征。
用户必须明确启用此特征。
使用非标名称。
要求使用供应商前缀或不同名称。
要求使用供应商前缀或不同名称。
  1. DOM (文档对象模型)
  2. Element
  3. 特性
    1. accessKey
    2. attributes
    3. childElementCount
    4. children
    5. classList
    6. className
    7. clientHeight
    8. clientLeft
    9. clientTop
    10. clientWidth
    11. currentStyle
    12. firstElementChild
    13. id
    14. innerHTML
    15. lastElementChild
    16. localName
    17. name
    18. namespaceURI
    19. nextElementSibling
    20. onfullscreenchange
    21. onfullscreenerror
    22. openOrClosedShadowRoot
    23. outerHTML
    24. part
    25. prefix
    26. previousElementSibling
    27. runtimeStyle
    28. scrollHeight
    29. scrollLeft
    30. scrollLeftMax
    31. scrollTop
    32. scrollTopMax
    33. scrollWidth
    34. shadowRoot
    35. slot
    36. tabStop
    37. tagName
  4. 方法
    1. after()
    2. animate()
    3. append()
    4. attachShadow()
    5. before()
    6. closest()
    7. computedStyleMap()
    8. createShadowRoot()
    9. getAnimations()
    10. getAttribute()
    11. getAttributeNames()
    12. getAttributeNode()
    13. getAttributeNodeNS()
    14. getAttributeNS()
    15. getBoundingClientRect()
    16. getClientRects()
    17. getElementsByClassName()
    18. getElementsByTagName()
    19. getElementsByTagNameNS()
    20. hasAttribute()
    21. hasAttributeNS()
    22. hasAttributes()
    23. hasPointerCapture()
    24. insertAdjacentElement()
    25. insertAdjacentHTML()
    26. insertAdjacentText()
    27. matches()
    28. msZoomTo()
    29. prepend()
    30. querySelector()
    31. querySelector()
    32. querySelectorAll()
    33. querySelectorAll()
    34. releasePointerCapture()
    35. remove()
    36. removeAttribute()
    37. removeAttributeNode()
    38. removeAttributeNS()
    39. replaceChildren()
    40. replaceWith()
    41. requestFullscreen()
    42. requestPointerLock()
    43. scroll()
    44. scrollBy()
    45. scrollIntoView()
    46. scrollIntoViewIfNeeded()
    47. scrollTo()
    48. setAttribute()
    49. setAttributeNode()
    50. setAttributeNodeNS()
    51. setAttributeNS()
    52. setCapture()
    53. setPointerCapture()
    54. toggleAttribute()
  5. Events
    1. afterscriptexecute
    2. auxclick
    3. blur
    4. click
    5. compositionend
    6. compositionstart
    7. compositionupdate
    8. contextmenu
    9. copy
    10. cut
    11. dblclick
    12. DOMActivate
    13. DOMMouseScroll
    14. error
    15. focus
    16. focusin
    17. focusout
    18. fullscreenchange
    19. fullscreenerror
    20. gesturechange
    21. gestureend
    22. gesturestart
    23. keydown
    24. keypress
    25. keyup
    26. mousedown
    27. mouseenter
    28. mouseleave
    29. mousemove
    30. mouseout
    31. mouseover
    32. mouseup
    33. mousewheel
    34. MozMousePixelScroll
    35. msContentZoom
    36. MSGestureChange
    37. MSGestureEnd
    38. MSGestureHold
    39. MSGestureStart
    40. MSGestureTap
    41. MSInertiaStart
    42. MSManipulationStateChanged
    43. overflow
    44. paste
    45. scroll
    46. select
    47. show
    48. touchcancel
    49. touchend
    50. touchmove
    51. touchstart
    52. underflow
    53. webkitmouseforcechanged
    54. webkitmouseforcedown
    55. webkitmouseforceup
    56. webkitmouseforcewillbegin
    57. wheel
  6. 继承:
    1. Node
    2. EventTarget
  7. DOM 相关页面
    1. AbortController
    2. AbortSignal
    3. AbstractRange
    4. Attr
    5. ByteString
    6. CDATASection
    7. CSSPrimitiveValue
    8. CSSValue
    9. CSSValueList
    10. CharacterData
    11. ChildNode
    12. Comment
    13. CustomEvent
    14. DOMConfiguration
    15. DOMError
    16. DOMErrorHandler
    17. DOMException
    18. DOMImplementation
    19. DOMImplementationList
    20. DOMImplementationRegistry
    21. DOMImplementationSource
    22. DOMLocator
    23. DOMObject
    24. DOMParser
    25. DOMPoint
    26. DOMPointInit
    27. DOMPointReadOnly
    28. DOMRect
    29. DOMString
    30. DOMTimeStamp
    31. DOMTokenList
    32. DOMUserData
    33. Document
    34. DocumentFragment
    35. DocumentType
    36. ElementTraversal
    37. Entity
    38. EntityReference
    39. Event
    40. EventTarget
    41. HTMLCollection
    42. MutationObserver
    43. Node
    44. NodeFilter
    45. NodeIterator
    46. NodeList
    47. NonDocumentTypeChildNode
    48. ProcessingInstruction
    49. PromiseResolver
    50. Range
    51. StaticRange
    52. Text
    53. TextDecoder
    54. TextEncoder
    55. TimeRanges
    56. TreeWalker
    57. TypeInfo
    58. USVString
    59. UserDataHandler
    60. XMLDocument