Skip to main content

Class: DurationFormatter

Display the duration

Param

The duration in milliseconds to parse and display

Param

The language assets

Constructors

new DurationFormatter()

new DurationFormatter(units?: DurationFormatAssetsTime): DurationFormatter

Parameters

ParameterType
units?DurationFormatAssetsTime

Returns

DurationFormatter

Defined in

duration/dist/esm/index.d.mts:8

Properties

units

units: DurationFormatAssetsTime

Defined in

duration/dist/esm/index.d.mts:7

Methods

format()

format(duration: number, precision?: number, __namedParameters?: DurationFormatSeparators): string

Parameters

ParameterType
durationnumber
precision?number
__namedParameters?DurationFormatSeparators

Returns

string

Defined in

duration/dist/esm/index.d.mts:9