NEWCKEditor AI is here! Learn how to supercharge your editor with AI on our webinar.
Sign up (with export icon)

utils/dom/indexof

Api-module iconmodule

Functions

  • Chevron-right icon

    indexOf( node ) → number

    Returns index of the node in the parent element.

    Parameters

    node : Node

    Node which index is tested.

    Returns

    number

    Index of the node in the parent element. Returns 0 if node has no parent.