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

A Dart library to convert numbers to Arabic and English words with currency support.

arabic_num2words #

arabic_num2words is a Dart library that allows you to convert integers into words in both Arabic and English, with full support for currencies and numbers up to the trillions.


๐Ÿš€ Features #

  • โœ… Arabic & English language support
  • โœ… Currency formatting (USD, ุฑูŠุงู„, etc.)
  • โœ… Supports very large numbers (up to a trillion)
  • โœ… Clean and modular class-based design
  • โœ… Fully tested with package:test

๐Ÿ“ฆ Getting Started #

Add the dependency to your pubspec.yaml:

dependencies:
  arabic_num2words:
    git:
      url: https://github.com/AbdulrahmanKhulaidi/arabic_num2words.git

Or replace with the pub.dev URL once published.


๐Ÿ’ก Usage Example #

import 'package:arabic_num2words/arabic_num2words.dart';

void main() {
  final converter = NumberToWords();

  print(converter.convert(1234, language: 'ar')); // ุฃู„ู ูˆู…ุงุฆุชุงู† ูˆุฃุฑุจุนุฉ ูˆุซู„ุงุซูˆู†
  print(converter.convert(1234, language: 'en')); // One thousand two hundred thirty-four

  print(converter.convertWithCurrency(250, language: 'ar', currency: 'ุฑูŠุงู„ ูŠู…ู†ูŠ'));
  print(converter.convertWithCurrency(88, language: 'en', currency: 'USD'));
}

๐Ÿงช Testing #

Run the tests:

dart test

๐Ÿ“„ License #

MIT License. Feel free to fork, modify, and contribute.


๐Ÿ‘ค Author #

qaisy dev

Facebook | GitHub


Ready to make your Dart apps smarter with localized number-to-word conversion!

arabic_num2words #

A Dart package that converts numbers to words in Arabic and English. It supports:

  • โœ… Arabic and English output
  • โœ… Currency formatting
  • โœ… Large numbers up to a trillion

๐Ÿ”ง Usage #

import 'package:arabic_num2words/arabic_num2words.dart';

void main() {
  final converter = NumberToWords();

  print(converter.convert(1234, language: 'ar')); // ุฃู„ู ูˆู…ุงุฆุชุงู† ูˆุฃุฑุจุนุฉ ูˆุซู„ุงุซูˆู†
  print(converter.convert(1234, language: 'en')); // One thousand two hundred thirty-four

  print(converter.convertWithCurrency(250, language: 'ar', currency: 'ุฑูŠุงู„ ูŠู…ู†ูŠ'));
  print(converter.convertWithCurrency(88, language: 'en', currency: 'USD'));
}

โœ๏ธ Author #

qaisy dev */

2
likes
150
points
68
downloads

Documentation

API reference

Publisher

unverified uploader

Weekly Downloads

A Dart library to convert numbers to Arabic and English words with currency support.

Repository (GitHub)
View/report issues

License

MIT (license)

Dependencies

flutter

More

Packages that depend on arabic_num2words