0

How can I add a 3rd party framework into Playground? I've created a playground in my project workspace(see attached picture) but using the import statement throws an error for anything that is not a standard iOS framework. enter image description here

6
  • You need to use the Bridging Header because it's probably in Objective-C. Just put "#import <Parse/Parse.h>" into your Bridging file Commented Jun 28, 2015 at 21:22
  • I don't think that's it, in all the other files it imports fine as import Parse. This seems to be a playground specific import issue. Commented Jun 28, 2015 at 21:25
  • Oh I see, I just found this though which pretty much is your question: stackoverflow.com/a/24048331/3443689 Commented Jun 28, 2015 at 21:28
  • I wish that worked. But it does not. I revisit this issue every couple of months trying to find a solution. Commented Jun 28, 2015 at 21:41
  • plus one for wanting this capability in Xcode! Commented Jul 28, 2015 at 16:20

1 Answer 1

2

enter image description hereIn Xcode 7 this has finally become very easy! Open a playground and save it in your projects root directory. Add the import statement and bing, bang, boom, you're done.

I'm using XCode 7.2

Sign up to request clarification or add additional context in comments.

3 Comments

Really? Can you add a snapshot where the files(playground) and framework are?
@tika added to the answer
Must be morte to this as I cannot import a 3rd party framework used in my workspace.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.