i18n-sync

📁 zhailei31665431/i18n-sync-skill 📅 2 days ago
3
总安装量
3
周安装量
#55491
全站排名
安装命令
npx skills add https://github.com/zhailei31665431/i18n-sync-skill --skill i18n-sync

Agent 安装分布

opencode 3
gemini-cli 3
antigravity 3
github-copilot 3
codex 3
kimi-cli 3

Skill 文档

i18n-sync

Use this skill when you need to keep i18n keys in sync across frontend, backend, iOS, and Android.

Contract

  • Function pattern: customFn("key", { count: 0, name: userName })
  • Function name is configurable (functionNames)
  • Second argument must be an object/map literal
  • Translation storage is always flat JSON: { "key": "value with {param}" }

Commands

  • node skill-i18n-sync/index.js extract --config skill-i18n-sync/i18n-sync.config.json
  • node skill-i18n-sync/index.js validate --config skill-i18n-sync/i18n-sync.config.json
  • node skill-i18n-sync/index.js sync --config skill-i18n-sync/i18n-sync.config.json

What it does

  1. Extract keys and params from source code.
  2. Pull all project translation JSON from API once.
  3. Filter translations by extracted keys.
  4. Validate placeholders (translation side vs code side).
  5. Emit locale JSON into each platform output directory.
  6. Generate optional runtime formatter helpers for JS/Swift/Kotlin.

Default backend endpoint in this repository: POST /api/i18n/translations.

Artifacts

  • skill-i18n-sync/.artifacts/keys.json
  • skill-i18n-sync/.artifacts/report.json