I'm trying to make use of IB_DESIGNABLE in my app.
The problem is my app is huge and takes an appreciable amount of time to build (ie. many minutes), so I would like keep all my custom views in a separate target and have Interface Builder only build that target to satisfy.
Whatever I try, Xcode seems to build all the targets in my project when doing Interface Builder's "designable" build, even if I move all the storyboards and IB_DESIGNABLE classes into their own framework and remove them from all other targets. The majority of the code in question is written in Objective-C.
Is there anyway to configure or trick interface builder into only building the target I want it to build? I've tried googling but have failed to turn up anything that describes how interface builder decides what to build or how to influence it.
By received wisdom from an IB team member:
If you're looking for faster IBDesignable build times, put custom UI code in it's own framework. IB only builds the target w/ the designable
Here's an example of that strategy implemented in the wild.
Sure doesn't look like there's any way to accomplish this without the separate framework.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With