fix(types): support return type generics for waterfall hooks - #65
Conversation
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 6c6894107c
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: b7cc032029
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
Waterfall callbacks currently must return their first argument's type, preventing callers from declaring different results or allowing
voidwhile retaining typed inputs.Align
SyncWaterfallHookandAsyncSeriesWaterfallHookwith upstream's<T, R = AsArray<T>[0], AdditionalOptions>signature and propagateRthrough staged calls and inherited hook APIs.Compatibility: the second generic now specifies the return type. Existing explicit tap-option types must move to the third position, and previously emitted declarations that expand the old default second generic may need rebuilding.
Related Links
Upstream fix: webpack/tapable#191