-
-
Notifications
You must be signed in to change notification settings - Fork 581
feat(openapi-fetch): Enable per request middleware #2465
New issue
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
feat(openapi-fetch): Enable per request middleware #2465
Conversation
🦋 Changeset detectedLatest commit: 7f5ad65 The changes in this PR will be included in the next version bump. This PR includes changesets to release 3 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
❌ Deploy Preview for openapi-ts failed.
|
cd199fb
to
bd35e6b
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice! Thanks for taking the time to do this. In terms of functionality this looks good.
I've left some detailed comments mostly regarding readability.
This can be merged, but there seems to be an issue with Netlify. I do not know how that subsystem works (and I don't have time to look at it right now). I have asked for help on the maintainer chat. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Apologies, I have to walk back on this one.
It seems that middleware
is really a more appropriate plural of middleware
. Not middlewares
:
https://english.stackexchange.com/a/257139
So... The original parameter name as it was in the docs and how you have built it first was correct. Could you revert to that? (the internal variable names are less important, we can always change them later, but we're bound to the interface).
Sorry 🙈 (on the upside, we can merge w/o netlfiy after the revert).
979d7f3
to
7f5ad65
Compare
No worries! Have rolled it back to using the original doc name Appreciate the quick reviews from you :) |
Changes
This PR introduces request level middleware options enabling the same client level middleware feature to be applied per request. This fills the missing feature of the docs and the issue raised here #2005
How to Review
Checklist
docs/
updated (if necessary)pnpm run update:examples
run (only applicable for openapi-typescript)