persian-tools
Tools
TypeScript
Persian tools
PersianTools is a standalone, library-agnostic JavaScript that enables some of the Persian features for use in the JavaScript.
Features
- Convert Persian words to the number.
- Convert Numbers to Persian words.
- Add and remove commas to numbers.
- Convert Persian numbers to Arabic or English numbers and vice versa.
- Validate Iranian national number(code-e Melli).
- Validate Iranian legal id(shenase hoghoghi).
- Find city and province name by national code(code-e Melli).
- Bill calculator.
- Check Iranian Sheba(IBAN) validation and recognize bank information by sheba code.
- Validate Bank card number.
- Find Bank’s name by Card number.
- Validate the correctness of the text of the Persian language and clear the Arabic letters in the Persian text.
- Fix Persian characters in URL.
- Fix Persian zero-width non-joiner(Replace spaces by half-space)
- Convert Jalaali date-time into a time ago
- Get the Remaining Time of the Date
- Validate and find information of phone number.
Getting started
There are two main ways to get PersianTools.js in your JavaScript project:
via script tags or by installing it from NPM
and using a build tool like Parcel,
WebPack, or Rollup.
via Script Tag
Add the following code to an HTML file: