mercredi 27 février 2019

Difference between Dispatcher and event emitter when using flux in an React application?

In flux flow, we dispatch actions to store --> store will handle action and emit event --> the views listens to the event and give a call to the store to get the data.

Here I am confused since the time I am using react, For emitting an event from the store why should we use event emitter library and why not dispatcher?

Is there any specific reason that every one use some emitting library while emitting the change from the store instead of Dispatcher?

Aucun commentaire:

Enregistrer un commentaire