Skip to content

Conversation

@sjorobekov
Copy link
Collaborator

@sjorobekov sjorobekov commented Jan 30, 2026

The previous approach of serving the swagger page will run a single swagger documentation.

According to the docs updated serving documentation using .serveFiles

@sjorobekov sjorobekov requested a review from resure January 30, 2026 09:36
@sjorobekov sjorobekov marked this pull request as ready for review January 30, 2026 09:36
Copilot AI review requested due to automatic review settings January 30, 2026 09:36
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR updates the swagger-ui-express integration to support serving multiple swagger documents in a single application by replacing the serve middleware with serveFiles, as recommended in the swagger-ui-express documentation.

Changes:

  • Migrated from serve to serveFiles middleware for swagger-ui-express to enable multiple swagger document support
  • Consolidated TypeScript module augmentation for RouteContract from a separate @typing/validator.d.ts file into src/types.ts
  • Updated zod devDependency version and corrected package license metadata

Reviewed changes

Copilot reviewed 4 out of 6 changed files in this pull request and generated no comments.

Show a summary per file
File Description
src/openapi-registry.ts Updated swagger-ui-express imports and middleware usage from serve to serveFiles to enable multiple swagger document support; optimized schema retrieval by capturing it once during mount handler execution
src/types.ts Added module augmentation for @gravity-ui/expresskit RouteContract interface, previously located in src/@typing/validator.d.ts
src/@typing/validator.d.ts Removed file as module augmentation was consolidated into src/types.ts
src/index.ts Added import for ./types to ensure module augmentation declarations are included when package is imported
package.json Updated zod devDependency version and corrected license field from ISC to MIT
package-lock.json Updated lock file entries for zod version and license metadata

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

resure
resure previously approved these changes Jan 30, 2026
@sjorobekov sjorobekov merged commit 84c715b into main Jan 30, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants