Add tiny example to Client
This commit is contained in:
		| @@ -28,6 +28,23 @@ static DEFAULT_USER_AGENT: &'static str = concat!(env!("CARGO_PKG_NAME"), "/", e | ||||
| /// | ||||
| /// The `Client` holds a connection pool internally, so it is advised that | ||||
| /// you create one and reuse it. | ||||
| /// | ||||
| /// # Examples | ||||
| /// | ||||
| /// ```no_run | ||||
| /// extern crate reqwest; | ||||
| /// | ||||
| /// use reqwest::{Error, Client}; | ||||
| /// | ||||
| /// fn run() -> Result<(), Error> { | ||||
| ///     Client::new()?.get("http://httpbin.org/").send()?; | ||||
| ///     Ok(()) | ||||
| /// } | ||||
| /// | ||||
| /// fn main() { | ||||
| ///     run().unwrap(); | ||||
| /// } | ||||
| /// ``` | ||||
| #[derive(Clone)] | ||||
| pub struct Client { | ||||
|     inner: Arc<ClientRef>, | ||||
|   | ||||
		Reference in New Issue
	
	Block a user