The technologies used in this project are React, Next.js, Tailwind CSS, HardHat, Solidity, and Ethers.js.
First, clone the repo and install the dependencies:
git clone https://github.com/reddio-com/reddio-nft-marketplace.git
cd reddio-nft-marketplace
Update node to the version you have in package.json file.
yarn
Next, run a local Ethereum node:
npx hardhat node
Deploy the smart contract to the local node:
npx hardhat run scripts/deploy.js --network localhost
Running the above command should print out the addresses where the contract was deployed. Update .evn.local
with those values:
NEXT_PUBLIC_NFTMARKET_ADDRESS="your-nft-market-address"
NEXT_PUBLIC_NFT_ADDRESS="your-nft-address"
Create an account at Infura, create a project and enable Dedicated Gateways, update the values below in '.evn.local' accordingly.
NEXT_PUBLIC_IPFS_PROJECT_ID="your-infura-project-id"
NEXT_PUBLIC_API_KEY_SECRET="your-infura-project-secret"
Next, run the development server:
yarn dev
Notes: Make sure you choose the right network on your Metamask
- Fork this repo
- Add Sepolia network to your hardhat.config.js file with the following information,
sepolia: {
url: `https://sepolia.infura.io/v3/${INFURA_API_KEY}`,
accounts: [SEPOLIA_PRIVATE_KEY]
}
- Log in to Vercel
- Import from your repo
- For 'Build and Output Settings', overide 'Build Command' with
yarn next build
- Set environment variables under your project, include NEXT_PUBLIC_IPFS_PROJECT_ID, NEXT_PUBLIC_API_KEY_SECRET and NEXT_PUBLIC_SEPOLIA_API_KEY_SECRET
- Deploy