Skip to content

An isomorphic WebCrypto object for Javascript in Node and the browser

License

Notifications You must be signed in to change notification settings

TopGunBuild/webcrypto

Repository files navigation

🔑 @topgunbuild/webcrypto

An isomorphic WebCrypto for Javascript in Node and the browser, used in TopGun

npm bundlephobia License: MIT

What?

It is an isomorphic WebCrypto object that combines a great Node polyfill and Web Crypto API.

Install

npm install @topgunbuild/webcrypto

Usage

There's a simple hashing example below, but there are many more WebCrypto examples here.

const crypto = require('@topgunbuild/webcrypto')
// or
import crypto from '@topgunbuild/webcrypto';

crypto.randomUUID (); // => '43e16416-7a2a-4c00-b2e8-1ea7a57adfb9'

License

MIT