Skip to content

badgerblockchain/attendance-token

Repository files navigation

BadgerToken

Reward token and website interface for the Badger Blockchain Club at UW-Madison.

View the BadgerToken on Goerli TestNet etherscan.

Requirements

Follow the links to install if you don't have the project requirements installed on your machine.

Getting Started

  1. Clone the Project

    Go to the token repository and clone on your local machine with:

git clone https://github.com/badgerblockchain/attendance-token.git
cd attendance-token
  1. Install local instance of Hardhat
npm install
  1. Install the dependencies outlined in package.json using npm.
  2. To start the app use:
cd frontend
npm install
npm start

The local instance of the website should launch after the npm start cmd is executed.

  • only need to use npm install on the first run

Frontend

  1. Switch to the Goerli test network by opening MetaMask. If you do not see Goerli, then click on Show/hide test networks and toggle the option to "on". Goerli should populate in the list of testnets.

Screen Shot 2022-10-05 at 2 29 08 PM

  1. Import Token to Metamask by clicking on Import Token on the Goerli testnet. Use the following address 0x7700D96fEa6337a6CA1B1704E3CdF066e965b73b.

Screen Shot 2022-10-05 at 2 25 29 PM

  1. Copy and Paste the token address into the first box. The rest of the boxes should autofill. Then Add custom token.

Screen Shot 2022-10-05 at 2 25 38 PM

  1. Click on Connect Wallet, and make sure the wallet is connected to Goerli and the tokens have been imported
  2. Click on Attendance Reward. Tokens should be transfered to your account!

This is a work in progress readme, TODO ADD PICTURES, better descriptions, ensure all dependencies are accounted for

RANDOM NOTES to be used in development

Deploys a new token to the goerli testnet:

npx hardhat run scripts/deploy_token.js --network goerli

https://vittominacori.github.io/watch-token/create/ (TODO figure out how to add image to token)

VIDEO I HAVE BEEN WATCHING: https://www.youtube.com/watch?v=c8Pkz1NqWNw

IN PROGRESS

  • only use one contract called BadgerTest(update the name)
  • After the contract is deployed look it up on etherscan and set up the "contract" (make sure to user compiler 0.8.3)
  • check behavior by starting site and clicking button
  • put private keys in env vars
  • prettify front-end
  • change name to BadgerToken (or another name?)
  • add photo so that MetaMask recognizes it
  • determine better tokeneconomics (set amount, not unlimited number)