mirror of
https://github.com/tokio-rs/axum.git
synced 2024-11-22 15:17:18 +01:00
568394a28e
* support setting body type for #[debug_handler] * Use lookahead1 to give better errors and detect duplicate arguments * fix docs link
10 lines
252 B
Rust
10 lines
252 B
Rust
use axum_macros::debug_handler;
|
|
use axum::{body::BoxBody, extract::State, http::Request};
|
|
|
|
#[debug_handler(state = AppState, body = BoxBody)]
|
|
async fn handler(_: State<AppState>, _: Request<BoxBody>) {}
|
|
|
|
#[derive(Clone)]
|
|
struct AppState;
|
|
|
|
fn main() {}
|