I'm new to iOS development and using Xcode and I'm having trouble getting Alamofire to work within a Playground. There's some functionality I'd like to test out for proof of concept but the library is not linked to the Playground and I've tried getting it to play nicely. I have Alamofire set up to work within an iOS (not in a Playground) project before the installation instructions in the Github Alamofire repo were recently updated.
Any suggestions on how to get Alamofire to import properly in the Playground?
Here is what I consider to be the simplest straight line path:
Download and build Alamofire:
Configure the workspace with a playground file and Alamofire.
Carthage/Build/{iOS / OSX}
directory, drag the Alamofire.framework file into your link library list:{Project Name} -> {Target Name} -> Build Phases -> Link Binary With Libraries
Command-N (create file) -> {Platform} -> Source -> Playground
File -> Save as Workspace
. To be paranoid, I close the project / workspace and (re)open the workspace.import Alamofire
You can try moving library to
Then you can import and use it right in your playground
Apple provides excellent step-by-step instruction to do so here: Importing Custom Frameworks Into a Playground
You can create a playground within the project also like in this tutorial
Steps
Cocoa Touch Framework
target (it doesn't need to have unit tests)@testable import ModuleFramework