diff --git a/CHANGELOG.md b/CHANGELOG.md index b8a91cd..5284548 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,9 @@ +## [0.15.0] - 2025-05-08 + +### Changed + +- Open API specs config object is fully spread into the final output + ## [0.14.3] - 2025-04-27 upgraded dependencies: `jsr:@std/assert@^1.0.13`, `jsr:@std/path@^1.0.9`, diff --git a/deno.jsonc b/deno.jsonc index 706ee44..362c9c8 100644 --- a/deno.jsonc +++ b/deno.jsonc @@ -1,6 +1,6 @@ { "name": "@dklab/oak-routing-ctrl", - "version": "0.14.3", + "version": "0.15.0", "exports": { ".": "./mod.ts", "./mod": "./mod.ts" diff --git a/src/oasStore.ts b/src/oasStore.ts index a16b9b6..1ed89ea 100644 --- a/src/oasStore.ts +++ b/src/oasStore.ts @@ -59,6 +59,7 @@ export const updateOas = ( const updated = { ...existing, + ...specs, method, path: oasPath, request: { diff --git a/src/useOas.ts b/src/useOas.ts index 670b7de..0720b8d 100644 --- a/src/useOas.ts +++ b/src/useOas.ts @@ -74,7 +74,7 @@ const _useOas: UseOas = ( const generator = new OpenApiGenerator(registry.definitions); const apiDoc = generator.generateDocument({ - openapi: "3.0.0", + openapi: oasCfg.openapi || "3.0.0", info: { version: "1.0.0", title: "My API",