The generic of the APIRoute type does not specify the second generic type of APIContext. #9612
Closed
1 task done
Labels
- P2: nice to have
Not breaking anything but nice to have (priority)
feat: typescript
Related to TypeScript (scope)
Astro Info
If this issue only occurs in one browser, which browser is a problem?
No response
Describe the Bug
While typing through the APIRoute type to create an API based on the pages folder, the params parameter was not typed, so I checked the type and found that the APIRoute type was receiving one less generic.
What's the expected result?
Link to Minimal Reproducible Example
https://stackblitz.com/edit/github-eyozpb?file=src%2Fpages%2Fapi%2Fblog%2Fviews%2F%5Bslug%5D.ts
Participation
The text was updated successfully, but these errors were encountered: