This repo contains boilerplate code for Full-stack NFT project.
Use git clone https://github.com/LoboVH/nft-bazar-Hardhat-solidity-Next.js-Polygon-IPFS.git
to get the files in this repository onto your local machine.
Make a duplicate of .env.example
as .env
and fillout the environment varaibles.
Create a project in infura(or any other private RPC) and update the PROJECT_ID
with Endpoint and also update privatekey
with your Metamask private key.
Run npm install
to get all the dependencies.
- start the local Hardhat Node
npx hardhat node
- With that running, deploy contract on a seperate terminal window
npx hardhat run scripts/deploy.js --network localhost
-
Update
config.js
file with deployed address. -
start the app
npm run dev
- Make sure
PROJECT_ID
andprivatekey
are updated. - Now deploy contract on any one of the network available i.e. Polygon Mainnet or Mumbai network.
npx hardhat run scripts/deploy.js --network <specify the network>
- Again update
config.js
file with the deployed address. - start the app
npm run dev