randomuuid

1.0.1 • Public • Published

randomUUID

Polyfill for the crypto.randomUUID() method as proposed in the WICG randomUUID specification and recently implemented in Node.js v15.6.0.

Usage

Require module to polyfill crypto.randomUUID() method.

require('randomuuid')

NOTE: ESM importable version not yet available. See this issue for status.

API

See Node.js documentation for randomUUID() for API usage.

Note: The current implementation is based on Node.js lib/internal/crypto/random.js, however the intent of this project is to follow the spec, so node-specific details (such as the disableEntropyCache option) may or may not survive in future versions.

Readme

Keywords

Package Sidebar

Install

npm i randomuuid

Weekly Downloads

310

Version

1.0.1

License

MIT

Unpacked Size

6.78 kB

Total Files

6

Last publish

Collaborators

  • broofa
  • ctavan
  • piranna