Skip to content

janlelis/yyid-node.js

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

29 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

YYID for Node.js [ci]

  • Generates a UUID#4-like random string, but in contrast to RFC 4122, omits the static bits
  • Format: xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx (128bit randomness)
  • Use a crytographically solid source of randomness: crypto.randomBytes
  • See yyid.js for an ESM browser version

Install

$ npm install yyid-node

Usage

var yyid = require('yyid-node');
yyid(); // => '5ebd4295-92a2-c98b-9103-b1e5d16f2bfa'

Other Versions

YYID is available for more languages, such as Ruby, Elixir, and Rust.

About

Almost a random UUID in node.js

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published