🛩
Hijackr
Installation
Hijackr is available through CocoaPods. To install it, simply add the following line to your Podfile:
pod 'Hijackr'
How to Use
To register:
Hijackr.register()
To unregister:
Hijackr.unregister()
To hijack a request:
Hijackr.hijack(request: request, with: response)
Example:
let request = URLRequest(url: URL(string: "https://www.google.com")!)
let response = Hijackr.Response(statusCode: 200, body: "hello".data(using: .utf8))
Hijackr.hijack(request: request, with: response)
Author
michaelhenry, [email protected]
License
Hijackr is available under the MIT license. See the LICENSE file for more info.