redux-subscribe
redux-subscribe copied to clipboard
Possible to hook this up to Redux store?
Hi, I'm trying to use this in a way where I can subscribe directly to my Redux store (I work with state mainly thru store and not props). Is this even possible?
Have been trying for a couple of hours now but not got it working. What I would like to do is in my components:
import * as rsub from 'redux-subscribe'
const local = rsub(store.getState());
local.subscribe('foo', 'bar', localAction);
function localAction(path, prev, next) {
console.log('check out my new data: ', next);
}