FixIt JavaScript API
    Preparing search index...

    Function applyHighlightToText

    • Apply highlight tags to text at the given character index ranges.

      Parameters

      • text: string

        The source text to highlight.

      • indices: number[][]

        Array of [start, end] character index pairs.

      • highlightTag: string

        The HTML tag name to wrap highlights with.

      Returns string

      The text with highlight tags inserted.