I have an Angular application. Its working good, but as my application is getting bigger I\'m worried about the large number of dependencies that I have to inject in each contro
My approach is to use $injector
, when there are lots of dependencies:
app.controller('viewapps', ['$scope','$injector',function($scope,$injector){
var Appfactory = $injector.get('Appfactory');
var Menu = $injector.get('Menu');
//etc...
}]);
The advantages: