Interface

MutationRecord

MutationRecord

A MutationRecord represents an individual DOM mutation. It is the object that is passed to MutationObserver's callback.

View Source js/lib.dom.d.ts, line 5056

Members

NodeList

# addedNodes

Return the nodes added and removed respectively.

View Source js/lib.dom.d.ts, line 5059

string | null

# attributeName

Returns the local name of the changed attribute, and null otherwise.

View Source js/lib.dom.d.ts, line 5064

string | null

# attributeNamespace

Returns the namespace of the changed attribute, and null otherwise.

View Source js/lib.dom.d.ts, line 5069

Node | null

# nextSibling

Return the previous and next sibling respectively of the added or removed nodes, and null otherwise.

View Source js/lib.dom.d.ts, line 5074

string | null

# oldValue

The return value depends on type. For "attributes", it is the value of the changed attribute before the change. For "characterData", it is the data of the changed node before the change. For "childList", it is null.

View Source js/lib.dom.d.ts, line 5079

Node | null

# previousSibling

Return the previous and next sibling respectively of the added or removed nodes, and null otherwise.

View Source js/lib.dom.d.ts, line 5084

NodeList

# removedNodes

Return the nodes added and removed respectively.

View Source js/lib.dom.d.ts, line 5089

Node

# target

Returns the node the mutation affected, depending on the type. For "attributes", it is the element whose attribute changed. For "characterData", it is the CharacterData node. For "childList", it is the node whose children changed.

View Source js/lib.dom.d.ts, line 5094

MutationRecordType

# type

Returns "attributes" if it was an attribute mutation. "characterData" if it was a mutation to a CharacterData node. And "childList" if it was a mutation to the tree of nodes.

View Source js/lib.dom.d.ts, line 5099