From 2a880a7a44e255291c461aa8818e93b6d011d44b Mon Sep 17 00:00:00 2001 From: mojadev Date: Sun, 7 Jan 2024 20:44:39 +0100 Subject: [PATCH] doc: update readme --- .github/workflows/test.yml | 2 +- README.md | 5 +++++ 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index b9b3ee4..9563390 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -21,5 +21,5 @@ jobs: - run: npm install name: Install - - run: npm run test --max-workers ${{ steps.cpu-cores.outputs.count }} + - run: npm run test name: Test \ No newline at end of file diff --git a/README.md b/README.md index 1f57c11..6af05d0 100644 --- a/README.md +++ b/README.md @@ -8,6 +8,11 @@ Encrypt and decrypt files in your browser using the WebCrypto API. This project aims at simplicity: You don't get a lot of options, but it's dead to encrypt and decrypt a file using Public/Private keys. +```typescript +const encrypted = await encryptFile(file, publicKey); +const decrypted = await decryptFile(encrypted, privateKey); +``` + > _Disclaimer_: I am not a security expert and this project has no security audits. Do not use it if leaking information would put your personal safety at risk. ## Background