This project is a frontend application for a faucet that allows users to claim ProtoCoins (PRT) using their Ethereum wallets via MetaMask. It is built using Next.js and integrates with Web3.js for Ethereum blockchain interactions.
- Next.js: A React framework for server-side rendering and static site generation.
- React: A JavaScript library for building user interfaces.
- Web3.js: A library that allows interaction with the Ethereum blockchain.
- MetaMask: A cryptocurrency wallet browser extension that connects users to Ethereum dApps.
- React Toastify: A popular library for notifications in React applications.
- React Google ReCAPTCHA: A component for implementing Google reCAPTCHA in React applications for security.
To run this project locally, follow these steps:
- Clone the repository:
git clone https://github.com/your-frontend-repo.git
- Navigate to the project directory:
cd your-frontend-repo
- Install dependencies:
npm install
- Create a
.env.local
file and add the necessary environment variables:
NEXT_PUBLIC_RECAPCHA_SITE_KEY=your-recaptcha-site-key
To start the development server:
npm run dev
The application will be running on http://localhost:3000
.
- Mint ProtoCoins: Users can connect their MetaMask wallets and mint ProtoCoins.
- Transaction Viewing: View transaction details on Binance Smart Chain testnet.
- Rate Limiting: Implements daily rate limits using ReCAPTCHA for security.
The main functionality revolves around:
- Connecting to MetaMask: Users authenticate and interact with their MetaMask wallets to mint ProtoCoins.
- Handling Minting: Calls the backend API to mint ProtoCoins based on user requests.
- Transaction Monitoring: Displays transaction status and links to Binance Smart Chain testnet explorer.
Backend project: https://github.com/FranciscoCosta/Backend-ProtoCoin
Token project: https://github.com/FranciscoCosta/Faucet-Protocoin
This project is licensed under the MIT License.