@eqty/risc-zero-verifier-react

0.2.1 • Public • Published

RISC Zero Verifier

This is a verifier for RISC Zero zkVM execution receipts.

There is also a component with no UI available.

Usage

Basic usage with defaults:

import { Verifier } from "@eqty/risc-zero-verifier-react";

<Verifier />

Enable the journal parser. See the main repo for more details on the journal parser.

<Verifier enableJournalParser={true} />

Then journal parser registry can be changed, and a different IPFS gateway can be set.

<Verifier
  enableJournalParser={true}
  onStatus={onVerifierStatus}
  registryUrl="http://localhost:3000/registry.json"
  ipfsGateway="http://localhost:8080"
/>

A callback function can be passed in to receive status changes and use the status elsewhere on the page:

  const onVerifierStatus = (result) => {
    // result is either null or an object like this:
    // {
    //  verified: true/false,
    //  error: "an error message"
    // }
  };

<Verifier
  enableJournalParser={true}
  onStatus={onVerifierStatus}
/>

Styling

The component is unstyled, but has CSS classes defined, including dynamic CSS classes for verification state.

For more info see https://github.com/eqtylab/risc-zero-verifier

Readme

Keywords

none

Package Sidebar

Install

npm i @eqty/risc-zero-verifier-react

Weekly Downloads

1

Version

0.2.1

License

Apache-2.0

Unpacked Size

65.5 kB

Total Files

11

Last publish

Collaborators

  • pauldowman
  • yurkowashere
  • robtu
  • cameronfyfe
  • gregipp