Skip to content

Sample app that demonstrates Solidity features with Celo. It allows users to rate their favorite politicians on-chain.

Notifications You must be signed in to change notification settings

PrimevalCoder/politirating

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Celo dApp: Politirating

Description

This is a sample app that demonstrates Solidity features with Celo. It allows users to rate their favorite politicians on-chain. Only the owner can add new politicians.

Live Demo

Politirating

Usage

Requirements

  1. Install the CeloExtensionWallet from the Google Chrome Store.
  2. Create a wallet.
  3. Go to https://celo.org/developers/faucet and get tokens for the Alfajores testnet. Make sure your balance shows the tokens.
  4. Switch to the Alfajores testnet in the CeloExtensionWallet.

Test

  1. If using the provided live demo, just choose your favorite politician, pick a rating, and click "Vote". Next, you should approve the contract to access your funds, then make the payment (1 cUSD required per vote).
  2. If you're setting up your own version of the dApp, you can also add new politicians from the owner address.

Project Setup

Dependencies

Install

npm install

Start

npm run dev

Build

npm run build

Warning

This project uses a deprecated version of webpack and subsequent modules.

Future work

  • Check the owner address by interrogating the contract rather than have the address hard-coded.
  • Add separate, more complex structures for political parties, add user reviews, etc.
  • Improve the UI.
  • ...

About

Sample app that demonstrates Solidity features with Celo. It allows users to rate their favorite politicians on-chain.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published