Is it possible to override the local when using intl.formatNumber

1 Answer 283 Views
General Discussions Localization
Michael
Top achievements
Rank 1
Michael asked on 12 Apr 2022, 01:16 PM

I was wondering if it was possible to override the locale used when using formatNumber with the IntlProvider. In the kendo-intl repo it seems you are able to do the below:

formatNumber(1234.5678, "n2", "de"); 
However, in the kendo-react-intl docs there are only two params for this method, and it doesn't seem to be possible in the react library.

 

Can anyone offer any advice on whether this is possible?


1 Answer, 1 is accepted

Sort by
0
Konstantin Dikov
Telerik team
answered on 14 Apr 2022, 08:36 AM

Hi Michael,

The IntlService is bound to a specific locale, which is why it accepts only the number and the format. The only thing that we can suggest is to use formatNumber within different IntlProvider as shown in the following examlpe:

As for exposing such feature in the KendoReact suite, you can log a feature request in out feedback portal, where other developers can vote for it:

 

Best Regards,
Konstantin Dikov
Progress Telerik

Virtual Classroom, the free self-paced technical training that gets you up to speed with Telerik and Kendo UI products quickly just got a fresh new look + new and improved content including a brand new Blazor course! Check it out at https://learn.telerik.com/.

Tags
General Discussions Localization
Asked by
Michael
Top achievements
Rank 1
Answers by
Konstantin Dikov
Telerik team
Share this question
or