mirror of
https://github.com/tokio-rs/axum.git
synced 2025-01-16 14:33:02 +01:00
Use http
re-export in docs (#1554)
This commit is contained in:
parent
8d2fb3618e
commit
3ab3e5f91d
2 changed files with 2 additions and 3 deletions
|
@ -82,7 +82,7 @@ pub trait FromRequestParts<S>: Sized {
|
||||||
/// use axum::{
|
/// use axum::{
|
||||||
/// async_trait,
|
/// async_trait,
|
||||||
/// extract::FromRequest,
|
/// extract::FromRequest,
|
||||||
/// http::Request,
|
/// http::{self, Request},
|
||||||
/// };
|
/// };
|
||||||
///
|
///
|
||||||
/// struct MyExtractor;
|
/// struct MyExtractor;
|
||||||
|
|
|
@ -5,8 +5,7 @@
|
||||||
//! Some examples of handlers:
|
//! Some examples of handlers:
|
||||||
//!
|
//!
|
||||||
//! ```rust
|
//! ```rust
|
||||||
//! use axum::body::Bytes;
|
//! use axum::{body::Bytes, http::StatusCode};
|
||||||
//! use http::StatusCode;
|
|
||||||
//!
|
//!
|
||||||
//! // Handler that immediately returns an empty `200 OK` response.
|
//! // Handler that immediately returns an empty `200 OK` response.
|
||||||
//! async fn unit_handler() {}
|
//! async fn unit_handler() {}
|
||||||
|
|
Loading…
Reference in a new issue