As title, I'd like to use more than one controller inside some sub-view
routes.js (eg.):
.state("multi",{
url: "/multi",
views: {
"": {
templateUrl: "multipleView.htm",
controller: "MainCTRL",
controllerAs: "ctrl"
},
"viewA@multi": {
templateUrl: "testingBlock.htm",
controller: ["CtrlOne", "CtrlTwo"],
controllerAs: "ctrl"
},
});
Or should I put CtrlOne and CtrlTwo inside a third controller:
function CtrlThree($scope){
CtrlOne($scope);
CtrlOTwo($scope);
}