english_numbers

0.2.2 • Public • Published

The main function is:

exports.numberToEnglish = function(number, millionComma, hyphenated, aNotOne)

arguments

number

This is the integer in need of being converted to english.

millionComma

This specifies whether to place a comma after the million word, i.e a million, three hundred thousand

hyphenated

Whether to hyphenate numbers in the range [21-99], i.e twenty-one instead of twenty one.

aNotOne

When numbers start with a 1, whether to generate an English string that begins with 'a' instead of 'one', i.e 'a hundred and ten' as opposed to 'one hundred and ten'.

Readme

Keywords

none

Package Sidebar

Install

npm i english_numbers

Weekly Downloads

13

Version

0.2.2

License

ISC

Last publish

Collaborators

  • shyal