Contents

collapsesLargestUnit

A Boolean value indicating whether to collapse the largest unit into smaller units when a certain threshold is met.

Declaration

var collapsesLargestUnit: Bool { get set }

Discussion

An example of when this property might apply is when expressing 63 seconds worth of time. When this property is set to true, the formatted value would be “63s”. When the value of this property is false, the formatted value would be “1m 3s”.

The default value of this property is false.

See Also

Configuring the Formatter Options