Skip to content

phasehq/client-js-sdk

Repository files navigation

Javscript Client SDK for Phase

Phase SDK to encrypt data in client-side JavaScript applications

Install

npm i @phase.dev/phase-js or yarn add @phase.dev/phase-js

Import

import Phase from "@phase.dev/phase-js";

Initialize

Initialize the SDK with your APP_ID:

const phase = new Phase(APP_ID);

Usage

const ciphertext = await phase.encrypt("hello world");

Development

Install dependencies

npm install

Build

npm run build

Run tests

npm test