I have been trying to use "responseDecodable" method from Alamofire, but I'm getting "Generic parameter 'T' could not be inferred" error while using it.
Can someone guide me how to fix this?
As you can read in the documentation, using responseDecodable
is straightforward:
AF.request(...).responseDecodable(of: ResponseType.self) { response in
...
}