koajs / koa

Expressive middleware for node.js using ES2017 async functions
https://koajs.com
MIT License
35.11k stars 3.22k forks source link

Provide more typings for application's context and request/response #1726

Closed mihailik closed 1 year ago

mihailik commented 1 year ago

Few extra JSDoc decorations that convey types so end-users of the library get better experience:

Screenshot 2022-12-07 at 13 49 03

Similar to #1607 and the suggestion by @jaydenseric except no project changes, just tweaking JSDoc 👍

codecov[bot] commented 1 year ago

Codecov Report

Base: 99.61% // Head: 99.61% // No change to project coverage :thumbsup:

Coverage data is based on head (33a4dc9) compared to base (9d2afef). Patch has no changes to coverable lines.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## master #1726 +/- ## ======================================= Coverage 99.61% 99.61% ======================================= Files 5 5 Lines 521 521 Branches 145 145 ======================================= Hits 519 519 Misses 2 2 ``` | [Impacted Files](https://codecov.io/gh/koajs/koa/pull/1726?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=koajs) | Coverage Δ | | |---|---|---| | [lib/application.js](https://codecov.io/gh/koajs/koa/pull/1726/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=koajs#diff-bGliL2FwcGxpY2F0aW9uLmpz) | `98.43% <ø> (ø)` | | Help us with your feedback. Take ten seconds to tell us [how you rate us](https://about.codecov.io/nps?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=koajs). Have a feature suggestion? [Share it here.](https://app.codecov.io/gh/feedback/?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=koajs)

:umbrella: View full report at Codecov.
:loudspeaker: Do you have feedback about the report comment? Let us know in this issue.