Hi. I am using the meteorflux:meteorflux package. But all the examples are for blaze.
I am trying to figure out how to have a react component subscribe to a state change
for example:
State.modify('State.User.userSignedIn', function(state = false) {
if (Action.is('USER_REGISTERED_WITH_EMAIL')) {
Accounts.createUser({
email: Action.email ,
password: Action.password
}, (err) => {
if (err) throw err;
return true;
});
}
});
I am not sure how I subscribe to the state change in my react component.
The documentation says
4.- Views automatically render themselves again when State changes.
Is this true for react components too?