From 93a821f9683ca5a119a96351ee05fdd2719edde9 Mon Sep 17 00:00:00 2001 From: RasmusKjeldgaard Date: Wed, 5 Feb 2025 10:50:02 +0100 Subject: [PATCH] Add phone number service info --- .../angular/localization/src/formatting-pipes.mdx | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/libs/extensions/angular/localization/src/formatting-pipes.mdx b/libs/extensions/angular/localization/src/formatting-pipes.mdx index 927d5dcb5e..30a1bab78b 100644 --- a/libs/extensions/angular/localization/src/formatting-pipes.mdx +++ b/libs/extensions/angular/localization/src/formatting-pipes.mdx @@ -48,6 +48,17 @@ If you need the formatted value in your component code instead of in the templat FormatNumberService.formatNumber(value: number, digitsInfo: string); ``` +## Phone Number + + + +If you need the formatted value in your component code instead of in the template, you can use the underlying service directly: + +```ts +PhoneNumberService.formatPhoneNumber(phoneNumber: PhoneNumber | string, chunk?: number, showCountryCode?: boolean); +``` + + ## Time & Date ### Time Only @@ -61,10 +72,6 @@ FormatNumberService.formatNumber(value: number, digitsInfo: string); -## Phone Number - - - ## Setup To set up the localization formatting pipes, you need to provide the necessary configuration token in the providers array of your module or component, or when bootstrapping your application. This configuration includes details such as the native currency, default language, country code, and time zone.