# Clone and enter the project
git clone https://github.com/mantramatt/omies-dapp-spa-template.git
cd omies-dapp-spa-template
# Install dependencies
yarn install
# Start the development server
yarn dev
That's it! Open http://localhost:5173 to see your dApp.
Tip
New to the project? Run the setup wizard to personalize the template:
Category
What You Get
🔗 Smart Contracts
Solidity + Foundry with deployment scripts, auto-verification
⚛️ Frontend
React 19, TypeScript, Vite, TanStack Router (file-based)
🎨 Design System
ShadCN UI + OMies visual identity (teal cartoon aesthetic)
👛 Web3
Wagmi + Viem + AppKit (MetaMask, WalletConnect, Keplr)
📦 Monorepo
Yarn workspaces with shared configs and independent packages
🚀 Deployment
Cloudflare Workers edge deployment, automatic contract verification
🛠 DX
Storybook, DevTools page, Kitchen Sink, hot reload
15+ Web3 components ready to use:
WalletConnectPill — Custom wallet button with balance + address
TransactionDialog — Review → Sign → Pending → Success flow
TokenInput — Amount input with max button + balance
AddressDisplay — Shortened address with copy + explorer link
NetworkBanner — Testnet/unsupported network warnings
ConnectGuard — Protect routes for connected users only
See all components →
omies-dapp-spa-template/
├── packages/
│ ├── contracts/ # 🔗 Foundry smart contracts
│ │ ├── src/ # Solidity source files
│ │ ├── script/ # Deployment scripts
│ │ └── test/ # Contract tests
│ │
│ └── webapp/ # ⚛️ React SPA (your main workspace)
│ ├── src/
│ │ ├── components/ # UI + Web3 components
│ │ ├── config/ # Chain configs (file-per-network)
│ │ ├── hooks/ # Custom React hooks
│ │ └── routes/ # TanStack file-based routes
│ └── public/ # Static assets
│
├── docs/
│ ├── dev/ # 📖 Developer documentation
│ └── agents/ # 🤖 AI assistant instructions
│
└── openspec/ # 📋 Project specifications
All commands run from the repository root .
Command
Description
yarn dev
Start webapp dev server (localhost:5173 )
yarn build
Build webapp for production
yarn storybook
Component development (localhost:6006 )
Command
Description
yarn contracts:test
Run Foundry tests
yarn contracts:test:watch
Tests in watch mode
yarn contracts:deploy:local
Deploy to local Anvil
yarn contracts:deploy:dukong
Deploy to Dukong testnet
yarn contracts:deploy:mainnet
Deploy to mainnet
# Add package to webapp
yarn workspace @dapp-evm/webapp add [package]
# Add dev dependency
yarn workspace @dapp-evm/webapp add -D [package]
Create packages/webapp/.env:
# Required for wallet connections
VITE_WALLETCONNECT_PROJECT_ID = your_project_id_here
Get your Project ID at WalletConnect Cloud .
For contracts, copy and configure:
cp packages/contracts/.env.example packages/contracts/.env
Network
Chain ID
RPC Endpoint
Explorer
Mainnet
5888
https://evm.mantrachain.io
blockscout.mantrascan.io
Dukong Testnet
5887
https://evm.dukong.mantrachain.io
explorer.dukong.io
Local (Anvil)
1337
http://localhost:8545
—
Create config file: packages/webapp/src/config/networks/[network].ts
Export chain definition and config object
Register in packages/webapp/src/config/chains.ts
Step-by-step guide →
MANTRA Mainnet (5888)
Contract
Address
Multicall3
0xcA11bde05977b3631167028862bE2a173976CA11
Wrapped OM
0xE3047710EF6cB36Bcf1E58145529778eA7Cb5598
Create2
0x4e59b44847b379578588920cA78FbF26c0B4956C
Createx
0xba5Ed099633D3B313e4D5F7bdc1305d3c28ba5Ed
MANTRA Dukong Testnet (5887)
Contract
Address
Multicall3
0xcA11bde05977b3631167028862bE2a173976CA11
Wrapped OM
0x10d26F0491fA11c5853ED7C1f9817b098317DC46
Create2
0x4e59b44847b379578588920cA78FbF26c0B4956C
Createx
0xba5Ed099633D3B313e4D5F7bdc1305d3c28ba5Ed
Type
Wallets
EVM
MetaMask, Rabby, WalletConnect-compatible
Cosmos
Keplr, Leap
# Deploy to testnet (auto-verifies on Blockscout)
yarn contracts:deploy:dukong
# Deploy to mainnet
yarn contracts:deploy:mainnet
The webapp deploys automatically via CI/CD to Cloudflare Workers:
Fork the repository
Create a feature branch: git checkout -b feature/amazing-feature
Commit changes: git commit -m 'Add amazing feature'
Push to branch: git push origin feature/amazing-feature
Open a Pull Request
This project is open source and available under the MIT License .