0.1.0 • Published 6 years ago
fancy-ids v0.1.0
Fancy-ids
Generates human-readable strings composed of english words, based on numbers. The calculation is fully reversible, so for example:
> f.fancyId(900000)
'Is-Year-Automatically-Different'
> f.fancyId('Is-Year-Automatically-Different')
900000
In other words, it is guaranteed that fancyId(fancyId(n)) === n
.
The intended use-case is to use these on the user-facing end in for example urls
where you have a database id as part of your url.
So https://mysite.com/items/Is-Recipe-Primarily-Embarrassed
instead of
https://mysite.com/items/12387632
.