hardhat-circom
Overview of the hardhat-circom npm package
Circom can be a lot to grasp
hardhat-circom to the rescue
Setup
Installationnpm install hardhat-circomrequire("hardhat-circom");import "hardhat-circom";
TasksUsage: hardhat [GLOBAL OPTIONS] circom --circuit <STRING> [--debug] [--deterministic] OPTIONS: --circuit limit your circom task to a single circuit name --debug output intermediate files to artifacts directory, generally for debug --deterministic enable deterministic builds for groth16 protocol circuits (except for .wasm) circom: compile circom circuits and template Verifier For global options help run: hardhat help
Basic configurationmodule.exports = { solidity: "0.6.7", circom: { // (optional) Base path for input files, defaults to `./circuits/` inputBasePath: "./circuits", // (required) The final ptau file, relative to inputBasePath, from a Phase 1 ceremony ptau: "pot15_final.ptau", // (required) Each object in this array refers to a separate circuit circuits: [{ name: "init" }], }, };j:~/best_dapp_ever/ $ tree βββ circuits βββ init.circom βββ init.json βββ pot15_final.ptauj:~/best_dapp_ever/ $ tree βββ circuits β βββ init.circom β βββ init.json β βββ init.wasm β βββ init.zkey β βββ pot15_final.ptau βββ contracts βββ InitVerifier.sol
Last updated