A simple ERC-20 token implementation that allows users to swap ETH for Mana Token. Built with Solidity, Hardhat, and a React frontend.
Ensure you have the following installed:
git clone https://github.com/welersonassis/mana-token.git
cd mana-tokencd contract
npm installnpx hardhat nodenpx hardhat ignition deploy ignition/modules/ManaToken.ts --network localhost- Implements the ERC-20 standard.
- Allows users to swap ETH for Mana Token.
- Mint function converts ETH into MANA tokens at a fixed rate of 1 ETH = 1,000,000 MANA.
- Includes security checks such as max supply and owner withdrawal.
Run contract tests using Hardhat:
npx hardhat testThe frontend is built with React and interacts with the smart contract using ethers.js.
cd frontend
npm installnpm run devThis will start the frontend at http://localhost:5173/.
MIT License. See LICENSE for details.