Questions tagged [react]
React (also known as React.js or ReactJS) is a JavaScript library for building user interfaces. It uses a declarative paradigm and aims to be both efficient and flexible.
585 questions
0 votes
1 answer
71 views
Error: reverted with reason string 'ERC20: insufficient allowance' with React, Wagmi and local HardHat node
I had an ERC-20 token staking project and was looking to migrate from using plain Ethers.js with MetaMask to Wagmi and RainbowKit. As expected, I had to rewrite a large part of the JavaScript code on ...
0 votes
0 answers
27 views
add a package to the uniswap interface project
I'm trying to fork the uniswap interface project I'm running: yarn add @myPackage-dex-tools/dex-lib The Ide Resolve the package reference fine The packages is added to the root node modules folder ...
0 votes
1 answer
96 views
Web3Button from Thirdweb-dev/react v4 sdk never loads, when set the active chain to base
i am working on a simple project, im using react v4 sdk , and everithing runds fine, im able to connect the wallet and read data from the users wallet. but when i set up the web3 button to sing a ...
0 votes
1 answer
85 views
Sending transaction through web3 in React failing for contract managed in Foundry
I am working on a full-stack React-NodeJs-Postgres app and combining it with solidity smart contracts managed using Foundry. I am using anvil to create a test blockchain to be able to make repeated ...
0 votes
1 answer
49 views
Thirdweb writeContract not working on hardhat node
Im using local hardhat node for deploying my contracts and using Thirdweb writeContract to execute a registerUser function from my smart contract, I've added the contract address, ABI, clientid and ...
0 votes
1 answer
190 views
TypeError: X is not a function (Uncaught (in promise) error)
I'm currently working on this specific issue when using state-changing contract methods using ethers 6.13.2. I've tried searching up similar issues and examples of this error but have not gotten any ...
1 vote
0 answers
41 views
Disconnected button state doesn't update when disconnecting, so Metamask doesn't pop-up when trying to connect back again
Context: NFT Smart Contract/ React App/ State Managed with Redux store Issue Description: When pressing "Disconnect" button state does not reset to initial state and Metamask connection ...
0 votes
1 answer
38 views
Error uploading file: Cannot read properties of undefined (reading 'add')
const ImgHash = `https://gateway.pinata.cloud/ipfs/${resFile.data.IpfsHash}`; // Correcting the contract call await contract.add(account, ImgHash); alert("...