UMD Web Utilities Library
    Preparing search index...

    Function capitalize

    • Capitalizes the first letter of a string

      Parameters

      • str: string

        The string to capitalize

      Returns string

      The string with first letter capitalized

      capitalize('hello'); // 'Hello'
      capitalize('hello world'); // 'Hello world'
      capitalize(''); // ''