1.7.0 • Published 1 year ago

number-to-english-words v1.7.0

Weekly downloads
-
License
ISC
Repository
-
Last release
1 year ago

number-to-english-words

Converts a numeric input to its equivalent English words representation.

  • Number should be passed as a string in quotation marks '' or ""
  • Can do conversion upto 36 digits (that's nine hundred and ninety nine decillion)

Installation

To use this package in your project. Install by running command

npm install number-to-english-words

Usage

To use the numberToWords function in your project, require it from the number-to-words package and call it with a numeric input. Here's an example:

import { convertToEnglish } from 'number-to-english-words'

const num = '12345';
const words = convertToEnglish(num);
console.log(words); // "twelve thousand, three hundred forty-five"

You can pass any numeric input to the numberToWords function and it will return the corresponding English words representation. If the input is not a valid number, the function will throw an error.

Github repos

https://github.com/saifullah0317/Number-to-words

License

This package is licensed under ISC

1.7.0

1 year ago

1.6.0

1 year ago

1.5.0

1 year ago

1.4.0

1 year ago

1.3.0

1 year ago

1.2.0

1 year ago

1.1.0

1 year ago

1.0.0

1 year ago