wire utoipa OpenAPI: #[utoipa::path] on all handlers, Scalar UI (#14)
This commit is contained in:
@@ -9,6 +9,7 @@ mod extractors;
|
||||
mod factory;
|
||||
mod handlers;
|
||||
mod mappers;
|
||||
mod openapi;
|
||||
mod routes;
|
||||
mod state;
|
||||
|
||||
@@ -52,6 +53,7 @@ async fn main() -> anyhow::Result<()> {
|
||||
|
||||
let app = axum::Router::new()
|
||||
.nest("/api/v1", routes::api_v1_router())
|
||||
.nest("/api", routes::docs_router())
|
||||
.layer(cors)
|
||||
.layer(TraceLayer::new_for_http())
|
||||
.with_state(app_state);
|
||||
|
||||
Reference in New Issue
Block a user