Skip to content

Conversation

@Dashron
Copy link
Owner

@Dashron Dashron commented Jun 13, 2025

ideally this would allow you to define the typing, but this works for now without ripping up a lot

@Dashron Dashron requested a review from Copilot June 13, 2025 02:46
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 improves type safety by adding explicit typing for query parameters in the RouterURL interface and updates the package version for an alpha release.

  • Adds a generic type parameter to the parse() function's return type in RouterURL.
  • Bumps the version number from alpha.6 to alpha.7 in package.json.

Reviewed Changes

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

File Description
src/middleware/router.ts Adds explicit generic type for query parameters in RouterURL interface.
package.json Updates the project version to reflect an alpha release bump.
Comments suppressed due to low confidence (1)

src/middleware/router.ts:28

  • Consider adding a comment explaining why the generic type parameter (Record<string, string | number>) was introduced here to clarify the expected structure of query parameters.
export interface RouterURL extends ReturnType<typeof parse<Record<string, string | number>>> {

@Dashron Dashron merged commit 17e607a into main Jun 13, 2025
10 checks passed
@Dashron Dashron deleted the fix/query-typing branch August 27, 2025 17:36
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.

2 participants