Created
August 16, 2023 20:29
-
-
Save Aviksaikat/d30151a7cdc04ac60032a2ace5275a0e to your computer and use it in GitHub Desktop.
Load a contract using interface in ape
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# create a interfaces folder inside the contracts folder & put the interfaces inside them | |
from ape import project | |
contract = project.contractName.at(contract_address) | |
# ex | |
uniswap_v2_router = project.ISwapV2Router02.at(Uniswap_V2_Router_address) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment