- Node 18+
ls-engines // Get minimum node version required for project based on dependencies.ls-engines --save// Get minimum node version required for project based on dependencies and SAVE it to the package.json.SEED_PHRASE="your seed phrase..."entered into a.envfile with your own seed phrase.
SEED_PHRASE="MY SEED PHRASE WORDS GO HERE"- Build & install zkverifyjs pack, install dependencies
npm install && npm run pack-and-install- Deploy the package with latest code
npm run pack-and-install- Install the tgz in frontend project, renaming the tgz in the command below as necessary
npm install ./path-to-package/zkverifyjs-0.2.0.tgz- Update
src/config/index.ts - Add a new proof to src/proofTypes including processor and formatter, and add export to
src/proofTypes/index.ts - Adding new
SEED_PHRASE_*environment variables will provide more throughput for tests if they are locked waiting for one to become available from theWalletPool
- Search for
ADD_NEW_PROOF_TYPEin the codebase.
If we want to add a new configured network (e.g. mainnet)
- Update
src/config/index.ts
- Search for
ADD_NEW_SUPPORTED_NETWORKin the codebase.
- Copy the
.env.templateinto.envfile and set the required values.
act workflow_dispatch -j build-and-test -P ubuntu-latest=ghcr.io/catthehacker/ubuntu:act-latest --network hostact workflow_dispatch -j build-and-publish -P ubuntu-latest=ghcr.io/catthehacker/ubuntu:act-latest --network host- Run a specific test
npx jest tests/verify.test.ts - Run all tests
npm run test- Run coverage for a specific file
npm run test:file:coverage src/api/connection - Run coverage for entire project
npm run test:coverageThe DOCS.md file gets generated from the README file onpre-commit automatically with husky, utilizing the ci/generateDocsReadme.js script. Do not edit DOCS.md directly. It will get overwritten.
This file is copied over and used in the zkVerify docs. See: https://github.com/HorizenLabs/zkverify-docs/blob/main/scripts/github_readme.js