Replies: 1 comment
-
Ok I got it, it can't be done without the abi, it seems like |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
hi, when I put the tx.data to the foundry's cast 4bytes-decode cli tool it can give me the name of the function, args, and some inputs I guess.
I googled and it seems like the same thing in ethers.js is
AbiCoder.defaultAbiCoder().decode(['type', 'type'], dataSlice(tx!.data, 4)
but the problem is the types are unknown, and cast can still provide the right output and ethers cannot without the right type (also it doesn't output the function name)
so
maybe this is not the method for this? How to decode correctly tx.data with ethers without the ABI? thank you:)
Beta Was this translation helpful? Give feedback.
All reactions