Search code examples
swiftinterface-buildercontrolsxcode8ibdesignable

Custom control within framework not configurable or visible in Xcode


I have created a small selection of custom controls that are tagged @IBDesignable to enable visual configuration within IB. They work perfectly in their parent project/workspace and, as I wanted them to be reusable, I've created a framework.

After importing the framework into another project, I can access the classes programmatically but there is no visual representation in IB and none of the @IBInspectable properties are displayed in the attributes inspector. There are no errors reported during build or run phases. I guess I'm missing something somewhere but does anyone have any pointers?


Solution

  • It would appear that this is not currently possible (using Carthage as a dependency manager at any rate) without considerable effort with workarounds. This kind of defeats the object IMO!

    For now it seems that you need to import the framework project into the product project. Explanation here but, for now, this seems dead in the water.