Number Translation is a Dart package designed to facilitate the conversion of numbers between different languages. It provides methods to translate numbers from English to various languages and vice versa.
Add the following line to your pubspec.yaml
:
dependencies:
number_translator: ^1.0.0
Then run:
$ flutter pub get
import 'package:number_translator/number_translator.dart';
From English:
String translatedNumber = NumberTranslator.translate('123', toLanguage: Language.bangla);
print(translatedNumber); // Output: '১২৩'
To English:
String translatedNumber = NumberTranslator.translateToEnglish('১২৩');
print(translatedNumber); // Output: '123'
- English ('en')
- Arabic ('ar')
- Bangla ('bn')
- Hindi ('hi')
- Chinese ('zh')
Contributions are welcome! If you find any issues or want to improve the package, feel free to open a pull request.
This project is licensed under the MIT License - see the LICENSE file for details.
Copyright (c) 2024 Tahmeedul Islam