Question about ethers.getContract LESSON 10 #1172
Replies: 2 comments
-
@AlexK020908 If there is no signer available, getContractAt (updated old one getContract) returns read-only contracts. Now, why were we using signer in tests? so the answer is that we wanted to change the state of the blockchain in tests (for understanding this click on the read-only above and read that.). |
Beta Was this translation helpful? Give feedback.
-
|
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
In lesson 10, as we are working on a deploy script that updates the front end :
for
why did we not specify a deployer/signer parameter like we did in the tests?
does the second parameter mean that we deployed the contract with the wallet address "deployer" ?
I have tried researching about this and this explanation came up:
ethers . getContract ( contractAddressOrName , contractInterface ) Returns a new connection to a contract at contractAddressOrName with the contractInterface. Prototype
What does contractInterface mean? and when should we include that second parameter like we did in tests/when shouldn't we?
Beta Was this translation helpful? Give feedback.
All reactions