Agent skill
Flutter Localization
Standards for multi-language support using easy_localization with CSV or JSON.
Install this agent skill to your Project
npx add-skill https://github.com/majiayu000/claude-skill-registry/tree/main/skills/other/other/localization-hoangnguyen0403-agent-skills-standar
Metadata
Additional technical details for this skill
- labels
-
localization l10n i18n easy_localization csv
- triggers
-
{ "files": [ "**/assets/translations/*.json", "**/assets/langs/*.csv", "main.dart" ], "keywords": [ "localization", "multi-language", "translation", "tr()", "easy_localization", "sheet_loader" ] }
SKILL.md
Localization
Priority: P1 (STANDARD)
Consistent multi-language support using easy_localization.
Format Selection
- CSV (Recommended for teams with translators):
- Non-technical editors can update easily
- Native Google Sheets compatibility via
sheet_loader_localization - Store in
assets/langs/(common convention)
- JSON (Developer-friendly):
- Nested structure support (e.g.,
items_count.zero) - IDE validation and autocomplete
- Store in
assets/translations/
- Nested structure support (e.g.,
Both formats work identically with easy_localization.
Structure
# CSV Format (Google Sheets workflow)
assets/langs/langs.csv
# OR JSON Format (nested keys)
assets/translations/
├── en.json
└── vi.json
Implementation Guidelines
- Bootstrap: Wrap root with
EasyLocalization. Always useawait EasyLocalization.ensureInitialized(). - Lookup: Use
.tr()extension on strings (e.g.,'welcome'.tr()). - Locale: Change via
context.setLocale(Locale('code')). - Params: Use
{}placeholders; pass viatr(args: [...]). - Counting: Use
plural()for quantities. - Sheets Sync: Use
sheet_loader_localizationto auto-generate CSV/JSON from Google Sheets.
Anti-Patterns
- Hardcoding: No raw strings in UI; use keys.
- Manual L10n: Avoid standard
Localizations.of; use GetX oreasy_localizationcontext methods. - Desync: Keep keys identical across all locale files.
Reference & Examples
For setup and Google Sheets automation: See references/REFERENCE.md.
Related Topics
idiomatic-flutter | widgets
Recommended Agent Skills
Expand your agent's capabilities with these related and highly-rated skills.
agent-ops-spec
Manage specification documents in .agent/specs/. Use when user provides requirements, acceptance criteria, or feature descriptions that need to be tracked and validated against implementation.
agent-ops-state
Maintain .agent state files. Use at session start, after meaningful steps, and before concluding: read/update constitution/memory/focus/issues/baseline consistently.
agent-ops-spec
Manage specification documents in .agent/specs/. Use when user provides requirements, acceptance criteria, or feature descriptions that need to be tracked and validated against implementation.
agent-ops-testing
Test strategy, execution, and coverage analysis. Use when designing tests, running test suites, or analyzing test results beyond baseline checks.
agent-ops-testing
Test strategy, execution, and coverage analysis. Use when designing tests, running test suites, or analyzing test results beyond baseline checks.
agent-ops-state
Maintain .agent state files. Use at session start, after meaningful steps, and before concluding: read/update constitution/memory/focus/issues/baseline consistently.
Didn't find tool you were looking for?