We added two methods to the LocalizationManager:

  • a helper method to search for a given translation key in the specified locale and to render it as plain text:
    String getTranslationPlain(String key, Locale locale, Object... parameters)
  • a method to get the configured default locale:
    Locale getDefaultLocale()

The first one was already available in the script service (under a different name: $services.localization.render()), so we exposed the second one too:

$services.localization.defaultLocale

Checkout the Localization Module documentation for more information.

Tags:
   

Get Connected