How pgurav-rgng/erc20pgtoken works
Project type and purpose
• This is an Ethereum smart-contract development project built with Hardhat. It implements a custom ERC20 token (PGToken) in Solidity, includes automated tests, and provides deployment scripts targeting the Sepolia testnet (and a local Hardhat node).
File structure
• Top-level files and dirs:
• contracts/ – Solidity source for PGToken, leveraging OpenZeppelin (Ownable, ERC20, Pausable, ReentrancyGuard, EIP-2612)
• scripts/ – JS/TS scripts to deploy and interact with the contract
• test/ – Hardhat‐based TypeScript tests
• ignition/ – additional deployment metadata (addresses, build info for Sepolia)
• hardhat.config.ts & tsconfig.json – Hardhat and TypeScript configuration
• typechain-types/ – auto-generated TS bindings for contracts and OpenZeppelin interfaces
• Key patterns:
• Modular contract code under contracts/
• Automated builds: Hardhat compile → TypeChain generation → test and deployment
• Separation of concerns: contracts, tests, scripts, deployment artifacts
README for additional insights
• Purpose: teaching ERC20 token creation, testing, and Sepolia‐net deployment
• Features: Ownable, mint/burn controls, pausable, permit approvals, secure guards
• Workflow steps: npm install → .env setup → hardhat node → deploy scripts → run tests