pub fn client() -> Client
Expand description
Construct a new Client
, capable of sending Request
s and running a middleware stack.
ยงExamples
let client = surf::client();
let req = surf::get("https://httpbin.org/get");
let res = client.send(req).await?;