Releases: MLSDev/TRON
Releases · MLSDev/TRON
5.5.0-beta.1
Introducing support for Swift Concurrency
let request: APIRequest<Int,APIError> = tron.codable
.request("status/200")
let result = try await request.sender().valueSwift Concurrency methods require Swift 5.5 / Xcode 13.2 / iOS 13 / tvOS 13 / macOS 10.15 / watchOS 6.
Read more usage examples in README.
Added
download(_:to:)anddownload(_:to:resumingFrom:)methods that createDownloadAPIRequestwith <URL, ErrorModel> generic constraints to simplify requests creation, where you need only URL from resulting operation.- Structured Concurrency support for Swift 5.5 and higher:
RequestSender,DownloadRequestSendertypes.
Fixed
- Issue, that could lead to sending network request with api stubs enabled, but Session.startRequestsImmediately property was set to false.
Breaking
- New deployment targets: iOS 11 / tvOS 11 / macOS 10.13 / watchOS 4 / Xcode 13. OS deployment targets now match minimum deployment targets, supported by Xcode 14.
5.4.1
Changed
- Improve Combine extensions to work better with stubs, that return synchronously.
Fixed
- Swift 5.4 warnings
5.4.0
Changed
- RxSwift dependency bumped to 6.0 and higher
5.3.0
Added
- Ability to modify
URLRequestsbefore it's adapted and sent:
tron.codable
.request("status")
.modifyRequest { $0.httpShouldHandleCookies = false }This feature uses Alamofire.RequestModifier closure, that can also be set without DSL on request instance directly:
let request : APIRequest<Post,Empty> = tron.codable.request("posts")
request.requestModifier = { urlRequest in
urlRequest.httpShouldHandleCookies = false
}5.2.0
Added
- Combine support on supported platforms through
publisher()method onAPIRequest,UploadAPIRequest,DownloadAPIRequest. APIError.isCancelledproperty, that tells, whether request, that errored, was cancelled by sender.
Changed
Alamofire.ParameterEncoding,JSONEncodingandURLEncodingare now exposed through TRON API and don't require importing Alamofire to use.
Deprecated
NetworkActivityPluginis deprecated on iOS 13 and higher, becauseUIApplication.isNetworkActivityIndicatorVisibleproperty it has been switching is deprecated on iOS 13 and higher.
5.1.0
Changed
- Several
Alamofiretypes that are exposed through TRON API's are now implicitly exported to allow using them without needing to writeimport Alamofire. SeeExports.swiftfile for a list of them.
5.0.3
Added
FileURLPassthroughResponseSerializer, which can be used as a response serializer forDownloadAPIRequestwhen you are only interested in URL of downloaded file.
Fixed
NetworkLoggerPluginnow correctly skips cancelled requests
5.0.2
- Added
DownloadAPIRequest.perform(withSuccess:failure:)method, similar toAPIRequestandUploadAPIRequestmethods.
5.0.1
BaseRequest.headersnow default toHTTPHeaders.defaultto allow sending Alamofire default headers such as "Accept-Language", "Accept-Encoding", "User-Agent".
5.0.0
Releasing version 5.0.0.