I'm following the instructions on the ui-router wiki which relates to working with resolves. If I follow the instructions on the wiki I get the value shared in to the controller without an issue, if I include the controller by reference the value is undefined. What am i missing?
.state('intro', {
url: '/',
resolve:{
resA: function(){
return {'value': 'A'};
}
},
views: {
'content': {
templateUrl: 'views/home.html',
controller: function($scope, resA){
$scope.resA = resA.value;
}
},
'navigation': {
templateUrl: 'views/navigation.html'
}
} })
.controller('introController', ['$scope', function($scope,resA) {
$scope.resA = resA.value; //undefined