Hybrid Voting - Web3 Core

A decentralized voting system with a futuristic Web3 aesthetic, powered by Solidity and Express.

SolidityHardhatEthers.jsJavaScriptExpressGlassmorphism

Share this project:

Project Overview

๐Ÿ—ณ๏ธ Hybrid Voting - Web3 Core

Web3 Banner

Hybrid Voting is a high-performance, decentralized voting system designed with a futuristic Web3 aesthetic. This project combines the transparency of the Ethereum blockchain with a premium, glassmorphism-based user interface to provide a secure and engaging governance experience.


โœจ Key Features

  • ๐Ÿ”— Blockchain Integrity: All votes are cryptographically signed and recorded on an Ethereum-compatible network (Hardhat).
  • ๐ŸŽญ Character-Based UI: Each candidate features unique cyberpunk avatars to enhance the Web3 gaming-inspired aesthetic.
  • ๐Ÿ’Ž Glassmorphism Design: Translucent, blurred UI elements with vibrant neon gradients for a cutting-edge feel.
  • โšก Real-Time Syncing: The dashboard automatically polls the blockchain to provide live vote counts without page refreshes.
  • ๐Ÿ›ก๏ธ Secure Verification: A hybrid approach where voters are verified against a local CSV database before interacting with the smart contract.
  • ๐Ÿ“ฑ Responsive & Interactive: Modern CSS animations and custom interactive toast notifications for instant feedback.

๐Ÿ–ฅ๏ธ Desktop Interface

image
  • Full-width layout for massive data visualization.
  • Interactive candidate cards with hover effects.
  • Real-time toast notifications for system status.
  • Neon-themed glassmorphism elements.

๐Ÿš€ Installation & Setup

1. Clone & Install

git clone <repository-url>
cd hybrid-voting
npm install

2. Hardhat Node (Blockchain)

cd blockchain
npm install
npx hardhat node

In a separate terminal, deploy the contract:

npx hardhat run scripts/deploy.js --network localhost

3. Backend Server

cd server
npm install

Configure your .env file in the root:

PORT=3001
RPC_URL=http://127.0.0.1:8545
PRIVATE_KEY=your_hardhat_private_key
CONTRACT_ADDRESS=deployed_contract_address

Run the server:

node index.js

4. Frontend Application

cd frontend
npx serve

Open http://localhost:3000 in your browser.

๐Ÿ“ Project Structure

hybrid-voting/
โ”œโ”€โ”€ blockchain/  # Smart contracts & Hardhat config
โ”œโ”€โ”€ frontend/    # Vanilla JS & CSS UI
โ”œโ”€โ”€ server/      # Node.js/Express API
โ””โ”€โ”€ README.md    # Documentation

๐Ÿงช Testing

  1. Blockchain: Ensure Hardhat node is running and contract is deployed.
  2. Backend: Verify server is connected to the RPC URL.
  3. Frontend: Use a browser with the serve URL.
  4. Voter Verification: Use names registered in server/voters.csv.
Hybrid Voting - Web3 Core | Daffathan Labs | Daffathan Labs