SuperAPI AI Directory

react-native-i18n

Coding & development

View repository

Updated 11-06 21:03

About this skill

React Native Internationalization

Targets React Native 0.8x on Hermes, Expo SDK 54–58, i18next 26 and react-i18next 17. The same patterns apply to other libraries (Lingui, FormatJS); only the translation API changes.

Core References

Topic Description Reference
Setup Locale detection, i18next + react-i18next init, resource layout, typed keys, language switching and persistence core-setup

Features

Topic Description Reference
Plurals & formatting Plural categories, interpolation, Intl dates/numbers/currency/relative time on Hermes, polyfills features-formatting
RTL I18nManager, start/end styles, icon mirroring, Expo supportsRTL, reload on direction change features-rtl

Best Practices

Topic Description Reference
Workflow Key naming, extraction, missing-key checks, pseudo-localization, per-app language settings, store metadata best-practices-workflow

Key Recommendations

  • Read locales from the OS — getLocales() (expo-localization) or getLocales() / findBestLanguageTag() (react-native-localize); never parse navigator.language
  • Format with Intl, not string concatenation — dates, numbers, currency and plurals depend on locale rules, not just language
  • One key per message, full sentences — no concatenated fragments; give translators context
  • Use start/end, not left/right — layouts mirror automatically when RTL is on
  • Direction changes need a reload — I18nManager.forceRTL takes effect only after restarting the JS bundle
  • Declare supported locales natively — supportedLocales in the expo-localization plugin enables per-app language on Android 13+ and iOS