localingo 1.0.0 copy "localingo: ^1.0.0" to clipboard
localingo: ^1.0.0 copied to clipboard

Automatic localization package for Flutter with CLI tool for generating translations using Free Translate API. Features type-safe keys, runtime locale switching, and beautiful terminal UI.

        ),
      ],
    ),
  ),
);

} }


### Placeholders & Dynamic Text

Your `en.json`:
```json
{
  "greeting": "Hello, {name}!",
  "items_count": "{count} items in cart"
}

Usage:

// With LocaleKeys (type-safe)
Text(LocaleKeys.greeting.replaceAll('{name}', 'John'))
Text(LocaleKeys.itemsCount.replaceAll('{count}', '5'))

// Or using the old way with string keys
Text('greeting'.tr().replaceAll('{name}', 'John'))

📖 API Reference #

LocaleKeys (Auto-Generated) #

Type-safe constants generated from your en.json:

class LocaleKeys {
  static String get appName => 'app_name'.tr();
  static String get welcome => 'welcome'.tr();
  static String get greeting => 'greeting'.tr();
  // ... all your keys
}

Usage:

// Use directly (recommended)
Text(LocaleKeys.appName)

// Or use string keys directly
Text('app_name'.tr())

🔧 Troubleshooting #

Q: Translation failed with timeout error?

  • A: The free API may be rate-limited. Wait a moment and try again. The package has automatic retry logic.

Q: Some translations look wrong?

  • A: Auto-translation is good but not perfect. Review and edit generated JSON files manually for production apps.

Q: Can I edit generated translations?

  • A: Yes! Edit the generated ar.json, fr.json, etc. files directly. Re-running the CLI won't overwrite them unless you delete them first.

Q: Do I need an API key?

  • A: No! Multilingo is 100% free with no API keys required.

🤝 Contributing #

We welcome contributions from developers around the world! 🌍

  1. Fork the repository ), ], ), ), ); } }

### Placeholders & Dynamic Text

Your `en.json`:
```json
{
  "greeting": "Hello, {name}!",
  "items_count": "{count} items in cart"
}

Usage:

// With LocaleKeys (type-safe)
Text(LocaleKeys.greeting.replaceAll('{name}', 'John'))
Text(LocaleKeys.itemsCount.replaceAll('{count}', '5'))

// Or using the old way with string keys
Text('greeting'.tr().replaceAll('{name}', 'John'))

📖 API Reference #

LocaleKeys (Auto-Generated) #

Type-safe constants generated from your en.json:

class LocaleKeys {
  static String get appName => 'app_name'.tr();
  static String get welcome => 'welcome'.tr();
  static String get greeting => 'greeting'.tr();
  // ... all your keys
}

Usage:

// Use directly (recommended)
Text(LocaleKeys.appName)

// Or use string keys directly
Text('app_name'.tr())

🔧 Troubleshooting #

Q: Translation failed with timeout error?

  • A: The free API may be rate-limited. Wait a moment and try again. The package has automatic retry logic.

Q: Some translations look wrong?

  • A: Auto-translation is good but not perfect. Review and edit generated JSON files manually for production apps.

Q: Can I edit generated translations?

  • A: Yes! Edit the generated ar.json, fr.json, etc. files directly. Re-running the CLI won't overwrite them unless you delete them first.

Q: Do I need an API key?

  • A: No! Multilingo is 100% free with no API keys required.

🤝 Contributing #

We welcome contributions from developers around the world! 🌍

  1. Fork the repository
  2. Create your feature branch (git checkout -b feature/amazing-feature)
  3. Commit your changes (git commit -m 'Add amazing feature')
  4. Push to the branch (git push origin feature/amazing-feature)
  5. Open a Pull Request

📞 Support & Community #

  • 💼 LinkedIn – Connect with the creator
  • ▶️ YouTube – Developer Youtube Channel

⭐ Support Localingo #

Enjoying Localingo?
Click the link below and tap the 👍 LIKE button on pub.dev — it really helps!

👉 https://pub.dev/packages/localingo


Made with ❤️ in Egypt 🇪🇬 | Spreading across the world 🌍

Breaking language barriers, one app at a time

⬆ Back to Top

24
likes
0
points
145
downloads

Publisher

unverified uploader

Weekly Downloads

Automatic localization package for Flutter with CLI tool for generating translations using Free Translate API. Features type-safe keys, runtime locale switching, and beautiful terminal UI.

Repository (GitHub)
View/report issues

License

unknown (license)

Dependencies

flutter, flutter_localizations

More

Packages that depend on localingo