https://github.com/ankitray-dev/voteblock
Blockchain e-voting using Solidity smart contracts for secure transactions and React.js for intuitive user interface design.
https://github.com/ankitray-dev/voteblock
blockchain contract decentralized ethersjs hardhat reactjs solidity volta
Last synced: 11 months ago
JSON representation
Blockchain e-voting using Solidity smart contracts for secure transactions and React.js for intuitive user interface design.
- Host: GitHub
- URL: https://github.com/ankitray-dev/voteblock
- Owner: ankitray-dev
- Created: 2024-04-25T02:21:12.000Z (almost 2 years ago)
- Default Branch: main
- Last Pushed: 2024-04-25T02:21:56.000Z (almost 2 years ago)
- Last Synced: 2025-01-17T05:29:15.288Z (about 1 year ago)
- Topics: blockchain, contract, decentralized, ethersjs, hardhat, reactjs, solidity, volta
- Language: JavaScript
- Homepage:
- Size: 391 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# VoteBlock A Decentralized Voting Application
This is a demo application to implement voting in solidity smart contract using ReactJS.
## Installation
After you cloned the repository, you want to install the packages using
```shell
npm install
```
After that create a .env file like shown in the .env.example file. To get a URL and private key of a volta network you can visit to this website [here](https://energy-web-foundation-origin.readthedocs-hosted.com/en/latest/volta-deployment/) and for the contract address you can follow the below process.
You first need to compile the contract and upload it to the blockchain network. Run the following commands to compile and upload the contract.
```shell
npx hardhat compile
npx hardhat run --network volta scripts/deploy.js
```
Once the contract is uploaded to the blockchain, copy the contract address and paste it in the .env file and src/Constant/constant.js file. You can also use another blockchain by writing the blockchain's endpoint in hardhat-config.
Once you have pasted your private key and contract address in the .env file, simply run command
```shell
npm start
```