How do i access myUrl object inside testController i have defined directive as below
paginationModule.directive('myDirective', function() {
return {
restrict: 'E',
scope: {
'myUrl': '=', // binding strategy
'myLinkText': '=' // binding strategy
},
controller: testController,
controllerAs: 'testCtrl',
bindToController: true,
template: gridPaginationTemplate
};
});
And from html i am passing some objects as below
<my-directive
my-url="paysCtrl.gridOptions"
my-link-text="paysCtrl.gridApi"></my-directive>
I have tried below options but geting undefined for all
console.info($scope[‘testCtrl’][‘myUrl’]);
console.info($scope[‘testCtrl’].myLinkText);