Tweakr
    Preparing search index...

    Function trimAll

    • Removes all whitespace characters from a string, including normal, Unicode, zero-width spaces, and HTML entities.

      Parameters

      • str: string

        The input string.

      Returns string

      The string with all whitespace removed.

      1.2.0

      trimAll("  hello   world  "); // "helloworld"
      trimAll(" a b c "); // "abc"
      trimAll("\u200Bfoo\u00A0bar"); // "foobar"