This is a base project for blockchain.
1. create new .env file
2. copy the content of .env.example file and paste it to .env file
3. replace the keys accordingly
4. npm install
Refer to Hardhat doc
# Compile Contracts
npx hardhat compile
# Deploy Contract
npx hardhat --network YOUR_NETWORK run scripts/deploy.ts
# Run Test
npx hardhat test
# Flatten
npx hardhat flatten contracts/YourContract.sol > FlattenContract.sol
# Verify
npx hardhat verify --network YOUR_NETWORK YOUR_CONTRACT_ADDRESS
# Replace contractAddress and contractAbi name in index.js
# Copy and paste generated json file from artifacts/contracts into frontend folder
# Right click index.html and select Open with Live Server