Merge the provided state object into the current state,

📘

Auto notifies listeners

Calls to setState and replaceState emit a change event that notifies listeners, only if the state has been changed by the call.

fluxapp.registerStore('user', { actions: { onUserLogin: 'user.login', }, onUserLogin: function(user) { this.setState({ token: user.token }); } });

👍

On to replaceState(state)