3 ms·
You can also accomplish the same effect in Angular by creating several "controllers" with focused responsibilities, then communicating via events with $rootScop
by dgritsko 14y ago
You can also accomplish the same effect in Angular by creating several "controllers" with focused responsibilities, then communicating via events with $rootScope.$broadcast (publish) and $scope.$on (subscribe). I've been using this pattern a lot recently and have found it does a great job encouraging separation of concerns.