This project demonstrates a basic Hardhat use case. It comes with a sample contract, a test for that contract, and a Hardhat Ignition module that deploys that contract.
Try running some of the following tasks:
npx hardhat help
npx hardhat test
REPORT_GAS=true npx hardhat test
npx hardhat node
npx hardhat ignition deploy ./ignition/modules/PokeNFT.jsOpen the hardhat terminal:
npx hardhat console --network localhostCreate an object to interact with the contract:
const pokenft = await (await ethers.getContractFactory("PokeNFT")).attach("CONTRACT ADDRESS HERE")Now you can call any contract method from the CLI (The use of await is to avoid receiving a Promise)
await pokenft.method()