A playground project used to discover new techniques, tools or just to try things out.
- Solidity
- ethers.js
- TypeScript
- Prettier
- dotenv
- Hardhat
- Mocha
- hardhat-gas-reporter
- Solidity Coverage
- Typechain
- Chainlink
- hardhat-deploy
The hardhat-etherscan plugin is used to verify the deployed contract programmatically and automatically, make sure the Etherscan API key is set in the .env
file. Verification will only be performed if the ETHERSCAN_API_KEY
environment variable is true and chainId
is 5 (a.k.a. chainId of Goerli test network).
At the moment there are two ways to deploy smart contracts. Using hardhat-deploy
is prefered.
npm run deploy
to deploy on default and temporary hardhat blockchain. To deploy on the goerli test network you can run npm run deploy-goerli
. The utils/deploy.ts
script will automatically deploy the contract to the specified network.
npm run hardhat-deploy
will use the hardhat-deploy
plugin to deploy the contract to the default and temporary hardhat blockchain. run npm run hardhat-deploy-goerli
to deploy to the goerli test network.
GOERLI_RPC_URL
andPRIVATE_KEY
are used to connect to the Goerli test network.PRIVATE_KEY
is used to sign transactions.ETHERSCAN_API_KEY
is used to verify the deployed contract.COINMARKETCAP_API_KEY
is used to see current gas prices in specified currency inside gas report.
- While deploying to the default and temporary hardhat blockchain, the pricefeed will be served by a mock. This is because there is no pricefeed available for a local test network.