Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Expose Swift Files to Objective-C within Framework

I have a framework with Swift and Objective-C in it. I have the statement at the top of my Objective-C class #import "MyFrameworkHeader.h" which I thought would expose my swift code to my Objective-C class however the compiler still says the symbols don't exist, how can I expose my Swift classes to my Objective-C classes within the same Framework?

like image 1000
Oxcug Avatar asked Jan 10 '23 04:01

Oxcug


1 Answers

Ugh, after smacking my head for a few hours then finally posting this question, within a few minutes I found the answer:

https://developer.apple.com/library/ios/documentation/Swift/Conceptual/BuildingCocoaApps/MixandMatch.html#//apple_ref/doc/uid/TP40014216-CH10-XID_82

Under the header: "Importing Swift into Objective-C"

like image 65
Oxcug Avatar answered Jan 18 '23 10:01

Oxcug