1.0.0 • Published 2 years ago
encrypt-node-js v1.0.0
Encrypt JS (encrypt-node-js)
Encrypt and Decrypt text with Encrypt JS.
Installation
Install Encrypt JS with Node JS Package Manager (NPM).
npm install encrypt-node-js
Usage
Below are two examples on how to use Encrypt JS.
Encrypt Text
const EncryptJS = require("encrypt-node-js")
try {
const key = await EncryptJS.generateKey()
const encrypted = await EncryptJS.encrypt(key, "{your_text}")
console.log(encrypted)
} catch (error) {
console.log(error)
}
Decrypt Text
const EncryptJS = require("encrypt-node-js")
try {
const key = await EncryptJS.generateKey()
const decrypted = await EncryptJS.decrypt(key, "{your_encrypted_text}")
console.log(decrypted)
} catch (error) {
console.log(error)
}
License
Encrypt JS is licensed with MIT.
1.0.0
2 years ago