Framework Development with Objective C and Swift
Provided below are the learnings I had as part of creating Frameworks with Objective-C and Swift Code.
Learning 1 (No bridging header required for interoperability for the Framework Targets)
There is no support for swift bridging headers in Xcode Framework Projects.
But how do you write Objective-C and Swift in same Project?
Just import your framework as a module in your swift class where you wanted to use the objective C created class.
Even if you try to add the bridging header manually, in a framework project, Xcode spits this below message.
“using bridging headers with framework targets is unsupported”
Digging Apple’s documentation gave the idea that, you do not need a Bridging header in Frameworks. You need bridging headers only for applications.
To access swift methods of Framework you should make them public
The github project provides an example.