Number, currency, and percent
Format numeric values with locale-aware browser formatters.
AngularTS provides three filters backed by Intl.NumberFormat:
numberformats a finite number.currencyuses currency style and defaults to USD.percentuses percentage style.
<span>{{ total | number:'en-US' }}</span>
<span>{{ total | currency:'en-US' }}</span>
<span>{{ completion | percent:'en-US' }}</span>
Numeric strings are accepted. Missing, empty, infinite, and nonnumeric values produce an empty string. Supply an explicit locale and currency for user-facing output.
Feedback
Was this page helpful?
Glad to hear it! Please tell us how we can improve.
Sorry to hear that. Please tell us how we can improve.