Skip to content

import IERC20 from ERC20 section:5 #98

Answered by PatrickAlphaC
arifulone asked this question in Q&A
Discussion options

You must be logged in to vote

You can import a contract from any contract that has the contract.

For example, the ERC20.sol contract imports IERC20.sol, so we can pulled the IERC20.sol from the ERC20.sol.

...although, for simplicity it would be better to import from IERC20.sol...

Replies: 1 comment 2 replies

Comment options

You must be logged in to vote
2 replies
@PatrickAlphaC
Comment options

@arifulone
Comment options

Answer selected by PatrickAlphaC
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants