Skip to content

Percent
@localizer/format-number 1.0.1

percentFormatter<T> ( options? ): ValueFormatter<T>

  • T extends number | bigint - The type of value to format. The value represent fraction of a whole, where 1.0 corresponds to 100%.
  • options - Optional configuration of the formatter.

This formatter provides a locale-aware way to represent percentage values.

TIP

If you prefer to use default settings, consider using a preconfigured percentage formatter. It simplifies the process by providing a ready-to-use configuration for common use cases.