Re:Show HN: Build your first real world React.js application
by yawgmoth on Wednesday September 07, 2016 @05:45PM
(#12448067)
It's an example of the thunk pattern. Thunks are used when you have an async call, e.g. getFoos. Then your action creator would be
Really useful for writing reducers that want to keep track of when you're fetching data from the server.
[ Parent
| on HN ]
Re:Show HN: Build your first real world React.js application
by hamandcheese on Thursday September 08, 2016 @01:56PM
(#12455385)
Yes, but in the parent comment a thunk wasn't being dispatched, but rather a closure around some unknown dispatch function is being called.