https://github.com/simonsinclair/n32
Express numbers in a form that can be conveniently and accurately transmitted between humans and computers.
https://github.com/simonsinclair/n32
base32 crockford douglas-crockford typescript
Last synced: 4 months ago
JSON representation
Express numbers in a form that can be conveniently and accurately transmitted between humans and computers.
- Host: GitHub
- URL: https://github.com/simonsinclair/n32
- Owner: simonsinclair
- License: mit
- Created: 2021-07-04T19:27:26.000Z (over 4 years ago)
- Default Branch: main
- Last Pushed: 2021-07-13T22:18:51.000Z (about 4 years ago)
- Last Synced: 2025-05-25T21:07:45.515Z (4 months ago)
- Topics: base32, crockford, douglas-crockford, typescript
- Language: TypeScript
- Homepage: https://github.com/simonsinclair/n32
- Size: 121 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# n32
> Express numbers in a form that can be conveniently and accurately transmitted between humans and computers.
## Install
```sh
npm i @simonsinclair/n32
```## Usage
```js
const { default: n32 } = require('@simonsinclair/n32');const randomNumber = 123456789;
const friendlyId = n32(randomNumber);console.log(friendlyId);
``````js
'3nqk8n';
```## API
### n32(number)
Returns a string.
#### number
Type: `number`.
The number to express.
## Supported browsers
IE11, and all modern browsers.