Class TwLocalizerExtensions
- Namespace
- TwBlazor.Localization
- Assembly
- TwBlazor.dll
Helpers for reading text from an ITwLocalizer.
public static class TwLocalizerExtensions
- Inheritance
-
TwLocalizerExtensions
- Inherited Members
Methods
Plural(ITwLocalizer, int, string, string, params object?[])
Gets the singular or plural form of a text, depending on count.
public static string Plural(this ITwLocalizer localizer, int count, string oneKey, string otherKey, params object?[] arguments)
Parameters
localizerITwLocalizerThe localizer to read from.
countintThe number that decides the form.
oneKeystringThe key of the singular form, used when
countis 1.otherKeystringThe key of the plural form.
argumentsobject[]The values for the text's placeholders.
Returns
- string
The formatted text.