tcorral / Hydra.js

Create a scalable, maintainable and module oriented system using Hydra.js
http://tcorral.github.com/Hydra.js
MIT License
102 stars 12 forks source link

Using a global singleton "BUS-like" Sandbox #8

Closed Ramonacus closed 11 years ago

Ramonacus commented 12 years ago

Hi, Tomás! There is one issue I would like to address you with the usage current Sandbox class. Currently you are using instances of this class in each module to handle notifications, which is fine but is an approach quite unusual. How about using Sandbox as singleton global BUS where all events are sent. I think this will help people get a better understanding of the communication between modules. Besides, this way you would not have to instantiate a new Sandbox object each time you started a module.

Please let me know you thoughts about this idea :)

tcorral commented 11 years ago

Fixed in version 3.0.0