zkt-sdk-js
zkToken | JS SDK
Installation and Running
As a package for node/typescript project
import Auth from "zkt-sdk";
const zkEth = new Auth("<SXT_ENDPOINT>", "<SECRETS_PROXY_ENDPOINT>");
console.log(zkEth);
As a bundled js file for the web
- Install all dependencies
yarn
- Build the bundled js file
yarn run build
The build files should be available in ./dist
folder
- Test
yarn run test
A new index.html
with sample usage code should be available in the ./dist
folder. In your browser open http://localhost:9000 and check the console logs. It watches any changes to the html file
Usage
<!DOCTYPE html>
<head>
<script src="./bundle.js"></script>
<script>
const zkWallet = new zkEth.Auth("<SXT_ENDPOINT>", "<SECRETS_PROXY_ENDPOINT>");
console.log(zkWallet)
</script>
</head>
</html>