Options
All
  • Public
  • Public/Protected
  • All
Menu

Index

Classes

Functions

Functions

Const defaultLocaleResolver

  • defaultLocaleResolver(i18n: I18n, locale: string): string[]
  • The default locale resolver.

    This resolver will add options.locale if provided (this function receives it inlined). In case nothing is set, then i18n.locale will be used. Additionally, adds the default locale to the list if i18n.enableFallback is set.

    Every locale added to the list will then be split apart; if pt-BR is the locale, then the list will be returned as ["pt-BR", "pt"].

    The default in case nothing is defined is ["en"].

    Parameters

    • i18n: I18n

      The I18n instance.

    • locale: string

      The locale that being analysed.

    Returns string[]

    The resolved locales.

Generated using TypeDoc