Closed Dhaiwat10 closed 2 years ago
When PR the useTransaction
hook was removed. Currently the mint price is updated from the useContract
hook getting the data from .cost()
const response = await nftContract.mint(1, {
value: ethers.utils.parseEther(mintPrice),
});
Found here
which is the same value as displayed on UI next to the mint button.
@Dhaiwat10 does this resolve this issue, or will there be a need to utilize the useTransaction
hook instead when it is working properly?
I think so, closing this one. Thanks!
Right now due to the nature of the
useTransaction
hook, the ether being passed to the transaction is statically set to0.05 ether
. This should be changed to be dynamic and adaptive to the contract.We should wait for the
useTransaction
hook to be updated to support passing in params when it is called (https://github.com/Developer-DAO/web3-ui/issues/174).