But how can we work with thunks, when a function is dispatched instead of an action? Could you provide a general solution to work with this kind of middleware?
Do we need to change EnhanceComponent source code each time, when we want to support custom middleware?
Hey, team. As far as I know, EnhanceComponent makes monkey patching for dispatch method to allow wrapping dispatched actions. Here is the patch
But how can we work with thunks, when a function is dispatched instead of an action? Could you provide a general solution to work with this kind of middleware? Do we need to change EnhanceComponent source code each time, when we want to support custom middleware?