A decentralized application built with Solidity, Ethers.js, and MetaMask.
Five smart contracts. No frameworks. No backend. Fully on-chain.
🔗https://blockverse-web3-dapp.netlify.app/
Connect MetaMask on Sepolia Testnet to interact with the contracts.
BlockVerse is a Web3 dApp I built to learn how smart contracts work in practice — not just in theory.
It covers the core pillars of Web3 development:
- ERC-20 — mint and track fungible tokens
- ERC-721 — issue verifiable NFT certificates
- DAO Governance — create proposals, vote, execute on-chain
- On-chain Storage — laws stored directly on the blockchain
- Guestbook — anyone can sign with their wallet and leave a permanent message
All contracts are deployed on Sepolia Testnet.
| Layer | Technology |
|---|---|
| Smart Contracts | Solidity ^0.8.20 |
| Frontend | Vanilla JS (ES Modules) |
| Blockchain Library | Ethers.js v6 |
| Wallet | MetaMask |
| Network | Sepolia Testnet |
| Standards | ERC-20, ERC-721, OpenZeppelin |
BlockVerse/
├── index.html
└── assets/
├── css/
│ └── style.css
└── js/
├── app.js
├── canvas.js
├── config/
│ └── contracts.js ← contract addresses + ABIs
├── core/
│ ├── connect.js ← wallet connection
│ ├── helpers.js ← shared UI utilities
│ ├── loader.js ← loads all data after connect
│ └── state.js ← global state manager
└── rooms/
├── room1.foundation.js
├── room2.treasury.js
├── room3.identity.js
├── room4.council.js
└── room5.guestbook.js
Stores on-chain laws. Only the owner can add laws. Anyone can read them.
Functions: addLaw, getLaw, setCityName
A mintable ERC-20 token built with OpenZeppelin.
Functions: mint, balanceOf, totalSupply, transfer
Issues NFT certificates with on-chain metadata.
Functions: mintCertificate, ownerOf, getCertificate, totalCertificates
On-chain governance. Create proposals, vote YES/NO, execute if passed.
Functions: createProposal, vote, execute, getResults
Anyone with a wallet can sign once and leave a permanent message on-chain.
Functions: sign, getEntry, getRecentEntries, totalEntries
Requirements:
- VS Code
- Live Server extension
- MetaMask browser extension
- Sepolia ETH from a faucet
Steps:
- Clone the repo
- Open folder in VS Code
- Add your contract addresses to
assets/js/config/contracts.js - Right-click
index.html→ Open with Live Server - Connect MetaMask → switch to Sepolia → interact
Do not open via
file://— ES Modules require a local server.
- How a frontend actually talks to a smart contract using Ethers.js
- The difference between
viewfunctions (free) and state-changing functions (gas) - How ERC-20 and ERC-721 standards work under the hood
- How DAO voting logic is implemented on-chain
- How to structure a modular JavaScript Web3 project
- Writing and deploying my own original smart contract (Guestbook)
- Token-gated voting — require BCT balance to cast a vote
- Staking contract — lock tokens and earn yield
- IPFS metadata — store NFT images off-chain
- Event listeners — real-time UI updates on contract events
- Multi-wallet support — switch accounts without refreshing