The ZK Layer for Solana
Light is a zkLayer enabling private program execution, purpose-built for Solana.
Developers can use Light to build applications such as
Light Protocol supports Development Containers and provides a container image with all dependencies which are needed for building and testing.
Visual Studio Code comes with out of the box support for Development Containers, but they are also supported by other editors:
If you still want to setup dependencies manually, these are the requirements:
To build the project, use the following commands:
./build.sh
./build-sdk.sh
In order to properly execute the prettier format pre-commit hook, you may first need to configure light-zk.js/husky/pre-commit as executable:
chmod ug+x ./light-zk.js/husky/*
Before doing any development or running any tets, you need to generate a new local keypair:
solana-keygen new -o ~/.config/solana/id.json
./test.sh
cd light-verifier-sdk/
cargo test
cd light-zk.js/
yarn test
cd light-circuits
yarn test
Tests are located in tests/
directory.
The default test is a functional test, setting up a test environment with a Merkle tree and an spl token, conducting two shields and unshields.
Tests can be executed in bulk or one by one.
cd light-system-programs/
yarn test
yarn test-verifiers
yarn test-merkle-tree
Generated using TypeDoc