Static
checkReturns true if the value is in the tree and it is at the index from the key
{boolean}
MerkleTreeUtils
Optional
options: { Static
checkReturns true if there is no value at the index from the key
{boolean}
MerkleTreeUtils
Optional
hasher: Hasher = Poseidon.hashStatic
compactCompact a merkle proof to reduce its size
{CompactMerkleProof}
MerkleTreeUtils
Optional
hasher: Hasher = Poseidon.hashStatic
compactConvert CompactMerkleProof to JSONValue.
{CompactMerkleProofJSON}
MerkleTreeUtils
Static
computeCalculate new root based on value. Note: This method cannot be executed in a circuit.
{Field}
MerkleTreeUtils
Optional
value: VOptional
valueType: Provable<V>Optional
options: { Static
computeCompute new merkle root by index and valueHashOrValueField
{Field}
MerkleTreeUtils
Optional
hasher: Hasher = Poseidon.hashStatic
computeCompute new merkle root by index and valueHashOrValueField, return new root and updates.
{{ actualRoot: Field; updates: [Field, Field[]][] }}
MerkleTreeUtils
Optional
hasher: Hasher = Poseidon.hashStatic
decompactDecompact a CompactMerkleProof.
{BaseMerkleProof}
MerkleTreeUtils
Optional
hasher: Hasher = Poseidon.hashStatic
jsonConvert JSONValue to CompactMerkleProof
{CompactMerkleProof}
MerkleTreeUtils
Static
verifyVerify the merkle proof.
{boolean}
MerkleTreeUtils
Optional
value: VOptional
valueType: Provable<V>Optional
options: { Static
verifyVerify the merkle proof by index and valueHashOrValueField
{boolean}
MerkleTreeUtils
Optional
hasher: Hasher = Poseidon.hashStatic
verifyVerify the merkle proof by index and valueHashOrValueField, return result and updates
{{ ok: boolean; updates: [Field, Field[]][] }}
MerkleTreeUtils
Optional
hasher: Hasher = Poseidon.hashGenerated using TypeDoc
Collection of utility functions for merkle tree