We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Would be very nice to add types for the new API to avoid accidentally breaking the code in the future. At least on the responses part.
Ref: https://plainenglish.io/blog/typed-express-request-and-response-with-typescript
Originally posted by @afathonih in #944 (comment)
The text was updated successfully, but these errors were encountered:
Turned out a lot easier as we can just do it without custom typing:
async function getQueuedSessionLength(request: Request<void>, response: Response<number>) { response.json((await ADTDatabase.PendingSessionsModel).chain().find().count()); }
Sorry, something went wrong.
No branches or pull requests
Would be very nice to add types for the new API to avoid accidentally breaking the code in the future. At least on the responses part.
Ref: https://plainenglish.io/blog/typed-express-request-and-response-with-typescript
Originally posted by @afathonih in #944 (comment)
The text was updated successfully, but these errors were encountered: