Convert Numbers to Persian with the ToPersianNumber Library

Convert Numbers to Persian with the ToPersianNumber Library

If you're working on React.js or Next.js projects and need to display numbers in Persian format, the ToPersianNumber library is exactly what you need! This simple, lightweight, and effective library converts English numbers into Persian numerals with ease, allowing you to enhance the user experience for Persian-speaking audiences.

Why ToPersianNumber?

Simple and Lightweight: This library does just one thing—converts English numbers to Persian—and it does it perfectly. No extra complexity, no bloat.

Perfect for React.js and Next.js Projects: Easily integrate this library into your React and Next.js apps.

Fast and Efficient: While simple, it performs its job quickly and accurately, making it ideal for any project that requires number localization.

How to Use**

  1. Install the library using npm:

npm install topersiannumber
        

Or using Yarn:

yarn add topersiannumber
        

  1. Import and use it in your project:

import { ToPersianNumber } from 'topersiannumber';

// Converting a number
const persianFormattedNumber = ToPersianNumber(123456); // Outputs: ??????
console.log(persianFormattedNumber);

        

Your Support Means a Lot! This is my first library, and I’d really appreciate your support! Feel free to star the repo and share it with others who might find it useful.

You can find the full repository here.

Happy coding! ??

Sepideh Goodarzian

BA and MA in the field of conservation and restoration of historical, cultural and ancient objects.

1 周

?? ??

Shadi Bagheri

Front-End Developer

1 个月

Great ??

要查看或添加评论,请登录

?Joodi ?的更多文章