Hey everyone, one question maybe someone could help me.
I need to find out best way to have shared structs between Factory/Created contracts.
Is it ok to have interface and put there all structs I wanna have in both contracts or better to use library?
Thanks in advance!
Apr 22, 2022, 11:53 AM
yes
btw depends on what you need
I usually place structs in a single interface
I usually place structs in a single interface
Apr 22, 2022, 11:59 AM
Thanks, so I have factory contract and I need to create sub contracts with create2 and pass as parameter struct
Apr 22, 2022, 12:01 PM
interface should be fine
Apr 22, 2022, 12:05 PM