Provides i18n functions. Accessed via the br/I18n
class.
Methods
(static) date(thing ToFormat)
Returns a data formatted according to the current locale settings.
Parameters:
Name | Type | Description |
---|---|---|
thingToFormat |
String | The data to format |
- See:
-
br-i18n/Translator:#formatDate
(static) date Time(thing ToFormat)
Returns a date time formatted according to the current locale settings.
Parameters:
Name | Type | Description |
---|---|---|
thingToFormat |
String | The date to format |
(static) get Translator()
Returns the Translator
used.
(static) i18n(thing ToFormat, mTemplate Argsopt)
Returns the translation for a message using the current locale.
Parameters:
Name | Type | Attributes | Description |
---|---|---|---|
thingToFormat |
String | The translation key. |
|
mTemplateArgs |
object |
<optional> |
Arguments provided by the template |
- See:
-
br-i18n/Translator:#getMessage
(static) number(thing ToFormat)
Returns a number formatted according to the current locale settings.
Parameters:
Name | Type | Description |
---|---|---|
thingToFormat |
String | The number to format |
- See:
-
br-i18n/Translator:#formatNumber
(static) time(thing ToFormat)
Returns a time formatted according to the current locale settings.
Parameters:
Name | Type | Description |
---|---|---|
thingToFormat |
String | The time to format |
- See:
-
br-i18n/Translator:#formatTime