MutationOperation: {
    addedTo: Element | null;
    attributes: Set<string>;
    currentTarget: Element;
    removedFrom: Element | null;
    target: Element;
}

Type declaration

  • addedTo: Element | null

    The element that the target was added to, i.e. it's new parent. It is null if the target was not moved to a new element during this round. It does not mean that this is its current parent.

  • attributes: Set<string>

    The list of attributes that were changed in this round.

  • currentTarget: Element

    The target that the callback was interested in.

    If selector is given as part of OnMutationOptions, then currentTarget will point to the target that matched the selector starting at the operation's target as the root. If the operation's target contains more than one element matching selector, the callback will be called once for each matching child.

    If target is given as part of OnMutationOptions, then currentTarget will be that element.

  • removedFrom: Element | null

    The element that the target was removed from, i.e. it's old parent. It is null if the target was not removed from a previous element during this round. It does not mean it did not previously have a parent, but that its removal was not observed.

  • target: Element

    The target that was changed.