请看这个小提琴:
scope.$watch('points', function (value) {
scope.console.push('scope.$watch');
});
由于某种原因,这在$scope.points
更改时不会触发
$scope.points.push(1);
为什么?
编辑澄清:
我希望看到这个:
events: ["scope.$watch","testUpdate()","scope.$watch","testUpdate()","scope.$watch","testUpdate()"]
但相反,我看到了这个:
events: ["scope.$watch","testUpdate()","testUpdate()","testUpdate()"]
注意没有scope.$watch
es