getTranslationLoader method

  1. @override
FileTranslationLoader getTranslationLoader(
  1. I18nProps i18nProps, {
  2. Locale? forcedLocale,
})
override

Implementation

@override
FileTranslationLoader getTranslationLoader(I18nProps i18nProps,
        {Locale? forcedLocale}) =>
    FileTranslationLoader(
      useCountryCode: false,
      fallbackFile: i18nProps.fallbackLanguage ?? 'en',
      basePath: i18nProps.path,
      // use the forcedLocale passed in at the App level, then use the forcedLocale in the config
      forcedLocale: forcedLocale ?? initialForcedLocale,
      decodeStrategies: [YamlDecodeStrategy()],
    );