gradum-kit - v0.1.0
    Preparing search index...

    Function formatMmSs

    • Function

      formatMmSs

      Parameters

      • seconds: number

        The duration in seconds. Fractions are truncated.

      • Optionalseparator: string = ""

        What to place between the minutes and seconds parts.

      Returns string

      The formatted duration.

      Format a duration in seconds in a compact, human-readable form such as "2m30s" — no zero-padding, and the minutes part dropped entirely when the duration is under a minute.