0

Most of the legit tutorial/demo out there are all talking about using Flux as a framework for the whole app. I am wondering if anyone has experience of building an app with multiple mini-flux-components. Because I am thinking in this way it might be easier to extract the mini-system out and then apply to other projects.

What do you guys think??

Deduplicator
  • 44,692
  • 7
  • 66
  • 118
Hao
  • 1,476
  • 3
  • 15
  • 20

1 Answers1

1

Nothing stopping you from instantiating multiple dispatchers, essentially creating multiple "instances" of Flux. The Dispatcher doesn't use any globals, so each instance is completely independent of the others.

I would avoid registering a Store with more than dispatcher, for the sake of keeping things simple and maintainable. To this end, a dispatcher should only span a fully modular domain of the application where the Stores under it's purview don't need to communicate with stores wired to different dispatchers.

Gil Birman
  • 35,242
  • 14
  • 75
  • 119