I follow the instructions to the T. Fresh install of all, yet getting the error:
"No Such module Alamofire"
Directions here:
In the meantime, you can simply add Alamofire as a git submodule, drag the Alamofire.xcodeproj file into your Xcode project, and add the framework product as a dependency for your application target.
And my screenshots
Adding Alamofire Into Our ProjectLaunch a new Xcode, SwiftUI based project and add the Alamofire dependency. You can use Cocoapods, Swift Package Manager or Carthage, whichever works the best for you. Once that's done, simply import Alamofire into your Swift class.
Make sure you haven't added any files from Alamofire to your project except for the Alamofire.xcodeproj
Here is step by step instruction:
import Alamofire
// in your source fileAlamofire.request(.GET, "http://httpbin.org/get")
// use AlamofireYou need to add the lib to 'the Link Binary With Libraries
' section also.
The target Dependencies
makes sure your lib is (re)-build before your target (useful when you makes changes to the lib) and the Link section makes sure the lib is available doing the link phase.
EDIT The above description works for most projects. However alarmofire just updated the process needed for this particular project here https://github.com/Alamofire/Alamofire
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With