reduxjs / react-redux

Official React bindings for Redux
https://react-redux.js.org
MIT License
23.37k stars 3.37k forks source link

Hooks minimal example on codepen appreciated #1269

Closed TimSusa closed 5 years ago

TimSusa commented 5 years ago

Hey,

I would like to get more information on how I could migrate to your new proposed hooks and yes, I have already read your documentation about that. I mean in most common cases we only have people using mapStateToProps/mapDispatchToProps and a little running example on codepen or jsfiddle would be very very nice.

Thanks in advance.

markerikson commented 5 years ago

We'd happily accept a PR to add a CodeSandbox example to the Hooks docs page.

Beyond that, please see these tutorials:

https://itnext.io/introducing-redux-hooks-1bf9c568ecc2

https://www.reddit.com/r/reactjs/comments/bhb3bc/react_redux_with_hooks_using_new_reactredux_71/

https://blog.jakoblind.no/react-redux-hooks/

timdorr commented 5 years ago

1267 is looking to add more examples as well. I think a PR is a better form for this kind of request.