Contents

precision(_:)

Modifies the format style to use the specified precision.

Declaration

func precision(_ p: FloatingPointFormatStyle<Value>.Currency.Configuration.Precision) -> FloatingPointFormatStyle<Value>.Currency

Parameters

  • p:

    The precision to apply to the format style.

Return Value

A floating-point format style modified to use the specified precision.

Discussion

The NumberFormatStyleConfiguration.Precision type lets you specify a fixed number of digits to show for a number’s integer and fractional part. You can also set a fixed number of significant digits.

See Also

Customizing style behavior