Open eugenekhoo1 opened 1 year ago
Hi, I am having issues getting the Token URIs using the useWeb3Contract function in NFTBox..as you can see my NFT boxes are not loading due to it being undefined.
The issue seems to be with the follow code, but i cant seem to debug it:
const { runContractFunction: getTokenURI } = useWeb3Contract({ abi: nftAbi, contractAddress: nftAddress, functionName: "tokenURI", params: { tokenId: tokenId, }, });
I have checked my subgraph and it does show the correct nftAddress that the getTokenURI function uses as one of it params
I am also able to get the ActiveItems that the 'listings.js' code is calling.
Tried to troubleshoot, but seems like all the params for the useWeb3Contract are in order...so im not too sure what the issue is with loading..
Repos: NextJS code https://github.com/eugenekhoo1/nextjs-nft-marketplace
NFT Contracts https://github.com/eugenekhoo1/hardhat-nft-marketplace
Graph https://github.com/eugenekhoo1/graph-nft-marketplace
Hi, I am having issues getting the Token URIs using the useWeb3Contract function in NFTBox..as you can see my NFT boxes are not loading due to it being undefined.
The issue seems to be with the follow code, but i cant seem to debug it:
I have checked my subgraph and it does show the correct nftAddress that the getTokenURI function uses as one of it params
I am also able to get the ActiveItems that the 'listings.js' code is calling.
Tried to troubleshoot, but seems like all the params for the useWeb3Contract are in order...so im not too sure what the issue is with loading..
Repos: NextJS code https://github.com/eugenekhoo1/nextjs-nft-marketplace
NFT Contracts https://github.com/eugenekhoo1/hardhat-nft-marketplace
Graph https://github.com/eugenekhoo1/graph-nft-marketplace