Skip to content

feat: checkContext type narrowing#28

Merged
fratzinger merged 2 commits intomainfrom
feat/check-context-type-narrow
Mar 11, 2026
Merged

feat: checkContext type narrowing#28
fratzinger merged 2 commits intomainfrom
feat/check-context-type-narrow

Conversation

@fratzinger
Copy link
Member

This pull request enhances the type safety and developer experience of the checkContext utility by introducing type narrowing based on the provided options or arguments. The changes ensure that when you use checkContext, the context object has its type, method, and path properties narrowed to the expected values, improving both type inference and error detection in your hooks. Additionally, the test suite has been expanded to verify these new type behaviors, and a linting command was added to the project configuration.

@cloudflare-workers-and-pages
Copy link

cloudflare-workers-and-pages bot commented Mar 11, 2026

Deploying feathers-utils with  Cloudflare Pages  Cloudflare Pages

Latest commit: 318f345
Status: ✅  Deploy successful!
Preview URL: https://44e2c586.feathers-utils.pages.dev
Branch Preview URL: https://feat-check-context-type-narr.feathers-utils.pages.dev

View logs

@fratzinger fratzinger merged commit 66d74ea into main Mar 11, 2026
11 checks passed
@fratzinger fratzinger deleted the feat/check-context-type-narrow branch March 11, 2026 14:09
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.

1 participant