DiffItemInsert (engine/model)



A single diff item for inserted nodes.



  • attributes : Map<string, unknown>

    Map of attributes that were set on the item while it was inserted.

  • length : number

    The length of an inserted text node. For elements, it is always 1 as each inserted element is counted as a one.

  • name : string

    The name of the inserted elements or '$text' for a text node.

  • position : Position

    The position where the node was inserted.

  • type : 'insert'

    The type of diff item.

  • internal

    _element : Element | undefined

    Reference to the model element that was inserted.

    Undefined if the diff item is related to text node insertion.