Options
All
  • Public
  • Public/Protected
  • All
Menu

Module string/ltrim

Index

Functions

Functions

  • ltrim(haystack: string, needle?: string): string
  • Removes all occurrences of needle from the beginning of haystack.

    example
     ltrim('abcabcHello', 'abc'); //=> 'Hello'
    ltrim(' Hello '); //=> 'Hello '

    Parameters

    • haystack: string

      string to trim

    • needle: string = ' '

      the thing to trim

    Returns string

Generated using TypeDoc