fix(deps): update dependency redux-thunk to v2.4.2 #35891
+1
−1
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR contains the following updates:
2.2.0
->2.4.2
Release Notes
reduxjs/redux-thunk (redux-thunk)
v2.4.2
Compare Source
This release removes an unused TS type that caused errors when users were type-checking libraries in
node_modules
.What's Changed
Full Changelog: reduxjs/redux-thunk@v2.4.1...v2.4.2
v2.4.1
Compare Source
This release adds an explicit plain
action
overload to theThunkDispatch
TS type to better handle inference of the return value in some cases.What's Changed
Full Changelog: reduxjs/redux-thunk@v2.4.0...v2.4.1
v2.4.0
Compare Source
This very overdue release makes several major improvements to the TypeScript types, and converts the actual source to TypeScript. Sorry for the delay!
Changelog
TypeScript Improvements
This release fixes several outstanding issues that had been reported with the types. An extra overload has been added to let TS correctly understand some generically-typed values being passed to
dispatch
, and the overloads have been reworked for additional compatibility.There's also a new
ThunkActionDispatch
type that can be used to represent howbindActionCreators
turns bound thunks into(arg) => thunkReturnValue
.Additionally, all of the generic args have been giving meaningful names instead of one-letter abbreviations (
S
->State
,E
->ExtraArgument
, etc), and we've added descriptive comments in the type definitions for clarity.Optional Global
Dispatch
Type ExtensionMost Redux apps have the thunk middleware enabled, but the default
Dispatch
andbindActionCreator
types only know about the standard behavior of a basic Redux store without any middleware. The thunk middleware types add to that type behavior, so thatDispatch
knows dispatching a thunk can actually return a value such as a Promise.We generally recommend inferring the type of
dispatch
and using that to create reusable types, including creating pre-typed hooks. However, some users may prefer to globally augment theDispatch
type to always use the additional thunk behavior.You can now
import 'redux-thunk/extend-redux'
to globally augment theDispatch
type as an opt-in change in behavior.Codebase Converted to TypeScript
We've gone ahead and converted the actual source to TS. Since the source was only 15-ish lines to begin with, most of the "conversion" time was just trying to convince TS that assigning
thunk.extraArgument = createThunkMiddleware
was a legal operation :)We also updated the build tooling:
Finally, the README has been updated with newer instructions and usage information.
What's Changed
applyMiddleware
by @iamandrewluca in https://github.com/reduxjs/redux-thunk/pull/279|
by @Philipp91 in https://github.com/reduxjs/redux-thunk/pull/317New Contributors
Full Changelog: reduxjs/redux-thunk@v2.3.0...v2.4.0
v2.3.0
Compare Source
Hello! There's a new sheriff in town...
This is only an update to the TypeScript typings for Redux 4.0 compatibility. After some discussion on the issues/PRs, we're going to be removing the typings completely in a 3.0 release soon. They will instead live in DefinitelyTyped, where they can be updated to match newer version of TypeScript and Redux at whatever pace they want to take. Farewell, typings! 🖖
Configuration
📅 Schedule: Branch creation - "before 4am on Monday" in timezone America/New_York, Automerge - At any time (no schedule defined).
🚦 Automerge: Enabled.
♻ Rebasing: Whenever PR is behind base branch, or you tick the rebase/retry checkbox.
🔕 Ignore: Close this PR and you won't be reminded about this update again.
This PR was generated by Mend Renovate. View the repository job log.