Open morion4000 opened 9 years ago
sisModules.init
allows sending options as the second parameter. If the scope
property is provided then the modules are going to use it, if not, a new isolated scope on $rootScope
is going to be used.
eg:
sisModules.init(function() {}, {scope: $scope});
Thank you very much for the effort, for now, if we can mention in the current documentation that one of the possible way to send data in and out of module is using
events.publish('facility-user', data);
and
events.subscribe('facility-user', function(data) {});
that'll be great. The above publish and subscribe works both in main app controller and modules.
After having a chat with @windmaomao, we agreed that we can/should implement different ways of exchanging data between modules and between modules and the apps.