a base64 lib for customize table
🏠 Homepage
(async () => {
let base64 = await require("@esbiya/base64-wasm")
const atob = require('atob')
const originString = atob("m/s+kDHLfcjVY44KyDnhkpFqo5E3xhJzD5yYOdAeAz8ANpK8OxAEoZQFWTYd3JkZhbEDddtDcy0xpPbeYDMDgTOilWpwp9+9fjKPaiOpauC/bXPzcQbflxyyGf0GVFwI2XjXE9D6a838KaCFIrsO/E1MlTv6bKszr0nazX4o7zMhpoazmvcBW6hJBCkv6TfaylQYmgQqU6jQpNTaw4MPuM8OdNDFtHHzTm/mrvRsxzcxD8QpNvlquA9bRRUYKPWugw+05dwmTAWii5afFnPrvg==")
const encodeString = "M/S~KdhlFCIvy44kYdNHKPfQO5e3XHiZd5YyoDaEaZ8anPk8oXaeOzqfwtyD3iKzHBedDDTdCY0XPpBEydmdGtoJLwPWP9~9FIkpAJoPAUc/BxpZCqBFLXYYgF0gvfWj2xIxe9d6A838kAcfjRSo/e1mLtV6BkSZR0NAZx4O7ZmHPOAZMVCbw6HibcKV6tFAYLqyMGqQu6IqPntAW4mpUm8oDndfThhZtM/MRVrSXZCXd8qPnVLQUa9BrruykpwUGW~05DWMtawJJ5AFfNpRVG=="
const testMap = "abcdefghjiklmnopqrstuvwxyzABCDEFGHJIKLMNOPQRSTUVWXYZ0123456789~/="
let cipherText = base64.encode(originString, testMap)
console.log(cipherText)
console.log(cipherText == encodeString)
let plainText = base64.decode(cipherText, testMap)
console.log(plainText)
console.log(plainText == originString)
})()
em++ -O3 -s WASM=1 -s EXPORTED_FUNCTIONS="['_free', '_malloc']" --no-entry -o ./build/base64.js ./src/base64.cc
👤 esbiya
- Github: @Esbiya
Contributions, issues and feature requests are welcome!
Feel free to check issues page. You can also take a look at the contributing guide.
Give a ⭐️ if this project helped you!
Copyright © 2021 esbiya.
This project is MIT licensed.
This README was generated with ❤️ by readme-md-generator