I want to fire an event when my multidimensional scope variable get changed i.e. element added, removed etc. I tried to do so using $scope.$watch and $scope.$watchCollection, but its not working.
This is the scenario.
$scope.variable=[{ID:1,text:'abc'},{ID:1,text:'abc'}];
$scope.content='';
$scope.$watch('$scope.variable',function(){
$scope.content=$scope.variable[0].text;
});
Any help ?