This Axiom Next.js 14 Quickstart provides a barebones framework through which you build full stack dApps on top of Axiom. The Axiom circuit and build files are inside the axiom/ folder and src/ contains a Next.js template.
Note that although this repository can be used in its current standalone form, it is most ideal to instead run npx create-axiom-client
to run the interactive Axiom project setup.
- Copy
.env.local.example
as a new file named.env.local
- Fill in the values in
.env.local
with your own values a.NEXT_PUBLIC_RPC_URL_[CHAIN_ID]
is your JSON-RPC provider URL ([CHAIN_ID]
is the chain ID number of the network you are using); you'll need to sign up for a free account with a node provider such as Alchemy or QuickNode b.NEXT_PUBLIC_WALLETCONNECT_PROJECT_ID
is your WalletConnect project ID; you'll need to sign up for a WalletConnect account - Run
npm install
(oryarn
/pnpm
) to install dependencies - Run
npm run dev
to start the local development server
If you make any changes to your circuit (./axiom/average.circuit.ts), run npm run build:circuit
to re-compile your circuit.
To use your own callback contract, change the CALLBACK_CONTRACT
address in ./src/shared/constants.ts, add your ABI to ./src/lib/abi/, and update the ABI import in ./src/app/prove/page.tsx.