i1n.ai
React Native 集成

React Native 本地化,一套代码。

从一组 JSON 文件管理 iOS 和 Android 的翻译。AI 翻译,CLI 同步,TypeScript 捕获缺失的键。

$ npx i1n init
src/screens/ProfileScreen.tsx
import { t } from 'i1n'

const ProfileScreen = () => (
  <View>
    <Text style={styles.title}>
      {t('profile.greeting', { name: user.name })}
    </Text>
    <Text>{t('profile.bio_placeholder')}</Text>
  </View>
)

为什么 React Native 团队使用 i1n?

一套本地化设置,两个平台

您的 JSON 区域设置文件可同时用于 iOS 和 Android。无需平台特定的翻译管理。

i18next 桥接模式

正在使用 react-i18next?继续使用。i1n 在您现有的设置中处理文件管理和 AI 翻译。

变量安全AI

像 {name} 和 {{count}} 这样的插值变量在 AI 翻译期间会被屏蔽。您的运行时永远不会中断。

离线就绪的区域设置文件

翻译会在构建时打包到您的应用中。无需为本地化字符串发出网络请求。

开始本地化您的 React Native 应用

永久免费。无需信用卡。