I have a base abstract contract which is inherited by 3 other contracts (all having the same interface). I am trying to use a factory contract to conditionally create instances of the derived contracts but the overall size of the factory is becoming too large (>24KB) on importing all 3 of them. I suspect it's because of the redundant code of base abstract contract which is common to all.
What would be the correct/best possible way to achieve this? Thanks