cloudflare / cloudflare/chanfana
Docs Issue: middleware Typescript errors
- Dominant language
- TypeScript
- Stars
- 766
- Forks
- 70
- Avg merge
- 25m
- Merged PRs (30d)
- 4
Description
Docs listed here produce typescript errors - https://chanfana.pages.dev/advanced-topics-patterns#middleware-and-interceptors
```
No overload matches this call.
The last overload gave the following error.
Argument of type 'typeof ProtectedEndpoint' is not assignable to parameter of type 'H<{ Bindings: Env; }, "/protected", BlankInput, Promise>'.ts(2769)
types.d.ts(774, 5): The last overload is declared here.
```
Any ideas?
Contributor guide
Research direction
Open the middleware and interceptors section at the linked documentation page and reproduce the reported TypeScript error. Trace the example and its type-checking context; done means the documented middleware example no longer produces the reported overload error.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- documentation
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 38/100