tidyuuid

1.0.0 • Public • Published

TIDY UUID

Returns locally ordered UUIDS. Total length is 32, where each character is 32 bit based on base32hex.

First 9 chars are for timestamp, follwed by 5 chars for counter of UUIDs within single milisecond and last 18 chars are "randomly" generated.

NOTES: Locally ordered means different instances running UUID() could have different/incorrect time settings. Due to speed and simplicity Math.random() is used for random values/numbers, this means tidyuuid is only pseudorandom.

Characteristics:

  • max timestamp 35184372088831 === 12 December 3084
  • max per milisecond === 32^5 === 33 554 432
  • "randomness" === 32^18 === 1.2379400392853803e+27

Readme

Keywords

Package Sidebar

Install

npm i tidyuuid

Weekly Downloads

0

Version

1.0.0

License

MIT

Last publish

Collaborators

  • danielcobo