getTranslations static method

Map<String, String> getTranslations([
  1. String? languageCode
])

Get translations for a specific language code If languageCode is null, auto-detect the device language

Implementation

static Map<String, String> getTranslations([String? languageCode]) {
  final code = languageCode ?? detectLanguage();

  // Return translations for the specified language, or English as fallback
  return app_translations.Translations.getTranslation(code) ??
      app_translations.Translations.getTranslation('en')!;
}