si-funciona
    Preparing search index...

    Function htmlEscape

    • Escape the characters that HTML gives a meaning to (&, <, >, " and '), so text from somewhere you don't control (a user's name, say) shows as itself when put into innerHTML or an attribute value, instead of becoming markup or script.

      Parameters

      • str: string

        The text to escape.

      Returns string