Skip to content
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

Docs update: recommend unknown instead of null as ThunkAction extraArgument type #3693

Merged

Conversation

phryneas
Copy link
Member

@phryneas phryneas commented Feb 9, 2020

Currently, the docs suggest null as type for the extraArgument generic argument of ThunkAction.
This only works if the ThunkMiddleware is invoked with null as extraArgument as well. The default value for ThunkMiddleware is unknown though, making these thunks incompatible with the default-typed ThunkMiddleware.

This change suggests to use unknown instead, which would work with Middlewares typed for any type of extraArgument.

@phryneas phryneas changed the title recommend unknown instead of null as ThunkAction extraArgument type Docs update: recommend unknown instead of null as ThunkAction extraArgument type Feb 9, 2020
@netlify
Copy link

netlify bot commented Feb 9, 2020

Deploy preview for redux-docs ready!

Built with commit cea0a8d

https://deploy-preview-3693--redux-docs.netlify.com

@markerikson markerikson merged commit 7b350c2 into reduxjs:master Feb 9, 2020
webMasterMrBin pushed a commit to webMasterMrBin/redux that referenced this pull request Aug 21, 2021
webMasterMrBin pushed a commit to webMasterMrBin/redux that referenced this pull request Aug 21, 2021
webMasterMrBin pushed a commit to webMasterMrBin/redux that referenced this pull request Aug 21, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants