@yookue/ts-lang-utils
    Preparing search index...

    Function appendIfMissing

    • Returns a string that concat the given text and suffix

      Parameters

      • Optionaltext: null | string

        the text to check

      • Optionalsuffix: null | string

        the suffix to append

      Returns undefined | null | string

      a string that concat the given text and suffix

      David Hsing

      appendIfMissing('foo', 'bar');    // 'foobar'
      appendIfMissing('foobar', 'bar'); // 'foobar'