Skip to main content

Questions tagged [wagmi-react]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
2 votes
0 answers
426 views

ContractFunctionExecutionError: The contract function "createCommitment" returned no data ("0x")

I am using WalletConnect's Web3Modal together with Wagmi. I am trying to use the hook provided by Wagmi -- usePrepareContractWrite and useContractWrite. Here is their documentation I applied the code ...
0xNike's user avatar
  • 23
1 vote
1 answer
119 views

wagmi error write() undefined

Hi all I think I am getting lost with my code. I am using WalletConnect for the modal. import React, { useEffect, useState } from "react"; import { View, Text, ActivityIndicator, ...
Agustin Gonzalez Ribas's user avatar
0 votes
1 answer
9 views

Getting 403 forbidden error when useWatchContractEvent hook is used in next, wagmi, react

I am getting 403 forbidden on every interval multiple times. I used the useWatchContractEvent() hook from wagmi in my next js app. Getting same error multiple times in intervals: POST https://sepolia....
mari0's user avatar
  • 1
0 votes
1 answer
37 views

Why wagmi with react returns object with numeric keys when fetch data from contract?

I have the issue that when I use useReadContract with abi , address an function name i receive the data like this: [{result: {0: value, 1: value}}]. The question is why this is possible when I have ...
blockchainer's user avatar
0 votes
0 answers
104 views

Cannot read properties of undefined (reading 'getDefaultChain')

in this code when i want call the function from contract i get this error: Cannot read properties of undefined (reading 'getDefaultChain') i use walletConnect V2 for connecting wallet and use etherjs ...
Elham Bahrami's user avatar
0 votes
0 answers
67 views

Getting error during setup when doing "npm i wagmi viem"

npm ERR! ERESOLVE unable to resolve dependency tree npm ERR! npm ERR! While resolving: [email protected] npm ERR! Found: [email protected] npm ERR! node_modules/typescript npm ERR! typescript@"^4....
Indul's user avatar
  • 29
0 votes
0 answers
468 views

Wagmi write contract

I have this code here import React from 'react'; import { usePrepareContractWrite, useContractWrite } from 'wagmi'; import lottoABI from './lottoABI.json'; import { parseEther } from 'viem'; // ...
Joe Code's user avatar
0 votes
0 answers
158 views

ABI encoding params/values length mismatch usePrepareContractWrite

I am using wagmi-react hooks to write contract data. Everything works fine with the useContractWrite() but having this issue when using usePrepareContractWrite() ABI encoding params/values length ...
Sagar Atalatti's user avatar
0 votes
1 answer
522 views

write is not a function from useContractWrite

I am getting this error in runtime when using usePrepareContractWrite my code is as follows from the wagmi documentation: const { config } = usePrepareContractWrite({ address: "...
Sagar Atalatti's user avatar