@tanker/crypto

Tanker SDK (cryptographic primitives)

Downloads in past

Stats

StarsIssuesVersionUpdatedCreatedSize
@tanker/crypto
79403.0.023 days ago5 years agoMinified + gzip package size for @tanker/crypto in KB

Readme

Tanker SDK (crypto)
This package is a dependency of the Tanker client SDKs for end-to-end encryption:

Usage

All functions of this package are synchronous, but you MUST ensure the underlying crypto library is ready before calling any of them:
import { ready, toString } from '@tanker/crypto';

const use = () => {
  const bytes = [104, 101, 108, 108, 111];
  const buffer = new Uint8Array(bytes);
  console.log(toString(buffer)); // 'hello'
};

// Either do:
ready.then(use);

// Or:
(async () => {
  await ready;
  use();
})();

More about Tanker

Tanker's client SDKs allow for seamless integration of client-side end-to-end encryption in your application.
Tanker is available for iOS, Android, and Web apps.
Read the documentation to get started.
Go to tanker.io for more information about Tanker.