From 6483cd5e63ca906a4a5da3058fea0d5c6c59f795 Mon Sep 17 00:00:00 2001 From: Tristan Druyen Date: Sun, 9 Mar 2025 23:09:30 +0100 Subject: [PATCH] Remove unneeded feature dependency --- axum-controller/Cargo.toml | 2 +- vendor/axum-typed-routing/examples/aide.rs | 28 ---------------------- vendor/axum-typed-routing/src/lib.rs | 2 +- 3 files changed, 2 insertions(+), 30 deletions(-) delete mode 100644 vendor/axum-typed-routing/examples/aide.rs diff --git a/axum-controller/Cargo.toml b/axum-controller/Cargo.toml index acf965c..4e84a08 100644 --- a/axum-controller/Cargo.toml +++ b/axum-controller/Cargo.toml @@ -13,7 +13,7 @@ version.workspace = true [dependencies] axum-controller-macros = { path = "../axum-controller-macros", version = "0.2.1" } -axum-typed-routing = { path = "../vendor/axum-typed-routing", version = "0.2.0", features = [ "aide"] } +axum-typed-routing = { path = "../vendor/axum-typed-routing", version = "0.2.0" } [dev-dependencies] axum = "0.8" diff --git a/vendor/axum-typed-routing/examples/aide.rs b/vendor/axum-typed-routing/examples/aide.rs deleted file mode 100644 index b3fd020..0000000 --- a/vendor/axum-typed-routing/examples/aide.rs +++ /dev/null @@ -1,28 +0,0 @@ -#![allow(unused)] -use aide::axum::ApiRouter; -use axum::extract::{Json, State}; -use axum_typed_routing::TypedApiRouter; -use axum_typed_routing_macros::api_route; - -#[api_route(GET "/item/:id?amount&offset" { - summary: "Get an item", - description: "Get an item by id", - id: "get-item", - tags: ["items"], - hidden: false -})] -async fn item_handler( - id: u32, - amount: Option, - offset: Option, - State(state): State, - Json(json): Json, -) -> String { - todo!("handle request") -} - -fn main() { - let router: ApiRouter = ApiRouter::new() - .typed_api_route(item_handler) - .with_state("state".to_string()); -} diff --git a/vendor/axum-typed-routing/src/lib.rs b/vendor/axum-typed-routing/src/lib.rs index 755d425..2873742 100644 --- a/vendor/axum-typed-routing/src/lib.rs +++ b/vendor/axum-typed-routing/src/lib.rs @@ -26,7 +26,7 @@ //! //! Please read the [`aide`] documentation for more information on usage. //! ``` -#![doc = include_str!("../examples/aide.rs")] +// #![doc = include_str!("../examples/aide.rs")] //! ``` use axum::routing::MethodRouter;