https://github.com/fasttime/number-name
Number to words converter
https://github.com/fasttime/number-name
Last synced: 7 months ago
JSON representation
Number to words converter
- Host: GitHub
- URL: https://github.com/fasttime/number-name
- Owner: fasttime
- License: isc
- Created: 2016-01-12T12:15:53.000Z (over 10 years ago)
- Default Branch: master
- Last Pushed: 2022-01-14T23:24:17.000Z (over 4 years ago)
- Last Synced: 2025-06-25T16:04:43.947Z (11 months ago)
- Language: JavaScript
- Size: 16.6 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: readme.md
- License: license.txt
Awesome Lists containing this project
README
# Number Name
A library to convert numbers to their English names.
## Setup Instructions
### In the Browser
To use the Number Name Library in your project, download
[number-name.js](https://github.com/fasttime/Number-Name/blob/master/lib/number-name.js) or
[number-name.min.js](https://github.com/fasttime/Number-Name/blob/master/lib/number-name.min.js)
from GitHub and include it in your HTML file.
```html
```
Alternatively, you can hotlink the online file.
```html
```
## Usage
```js
var name = numberName(12345);
// twelve thousand three hundred forty-five
```
```js
var name = numberName(-Math.PI);
// minus three point one four one five nine two six five three five eight nine seven nine
```
```js
var name = numberName(1e42);
// one tredecillion
```
*This is a preliminary documentation and may be subject to change at any time.*