Skip to main content

Scaffold

This scaffolds the full monorepo with Reown (AppKit, formerly Web3Modal) as the wallet provider. For just the frontend, add --template frontend.

Environment Setup

Get a Project ID from cloud.reown.com and set it in frontend/.env:
frontend/.env
A Project ID is required for Reown — without it, the app renders a “Missing configuration” screen instead of connecting.

Provider Setup

Reown initializes AppKit with a WagmiAdapter and wraps your app in WagmiProvider. The network comes from activeChain in lib/network.ts, which follows NEXT_PUBLIC_NETWORK — no per-provider chain edits needed.
components/Providers.tsx
Provider hierarchy: ThemeProviderWagmiProvider (from the AppKit adapter) → QueryClientProvider

Inco SDK Integration

The Inco SDK works with the walletClient provided by wagmi (which Reown/AppKit supplies). The network-aware client comes from lib/network.ts:
hooks/useConfLottery.ts

Dependencies