Skip to content

πŸ”’ Unified API for cryptographic operations in web and runtime environments, supporting Node.js, browsers, and other platforms

License

Notifications You must be signed in to change notification settings

nyxblabs/cryptonyx

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

6 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

cover npm version npm downloads bundle JSDocs License

πŸ›‘οΈ cryptonyx

πŸ”’ Unified API for cryptographic operations in web and runtime environments, supporting Node.js, browsers, and other platforms

This library provides a single api to use web-crypto and Subtle Crypto in both Node.js using Crypto Module and Web targets using Web Crypto API using Conditional Exports.

Requirements:

  • Node.js: Version 15 and above (this library provides no polyfills for older versions!) πŸ“¦πŸ”’
  • Browser: Secure Context (HTTPS/Localhost) in Supported Browsers πŸŒπŸ”’
  • Other Runtimes: Exposed globalThis.crypto and globalThis.crypto.subtle. (you can polyfill if needed) βš™οΈπŸ”’

πŸ“ Usage

Install:

# nyxi 
nyxi cryptonyx

# pnpm
pnpm install cryptonyx

# npm
npm install cryptonyx

# yarn
yarn add cryptonyx

Import:

// ESM
import { getRandomValues, randomUUID, subtle } from 'cryptonyx'

// CommonJS
const { subtle, randomUUID, getRandomValues } = require('cryptonyx')

🌱 Development

  • πŸ™ Clone this repository
  • πŸ“₯ Install latest LTS version of Node.js
  • πŸ”§ Enable Corepack using corepack enable
  • πŸ“¦ Install dependencies using nyxi πŸ§™ Always right package manager
  • πŸƒ Run nyxr dev

πŸ“œ License

MIT - Made with πŸ’ž

About

πŸ”’ Unified API for cryptographic operations in web and runtime environments, supporting Node.js, browsers, and other platforms

Topics

Resources

License

Code of conduct

Stars

Watchers

Forks

Sponsor this project