Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
$scope.$watch stopped firing
Message
General information
Forum:
Javascript
Category:
Other
Miscellaneous
Thread ID:
01611409
Message ID:
01611415
Views:
26
>>
>>noDirtyCheck is a directive. I add data in front to avoid the warnings from the VS.
>
>Instead of
>
>data-no:dirty-check
>
>I would have expected to see:
>
>data-no="dirty-check"
>
>>BTW, I was wrong saying that ng-change is not firing. I had a breakpoint on the wrong line. It does fire but in the code the $scope.showFinalized is always false regardless on what state the checkbox is.
>
>I don't know if this is the case or not, but I've gotten in the habit of adding an object into my scope and then adding the properties to it instead. Angular gets weird with scope inheritance and stuff can sometimes just not work.
>
>Ex.
>
>In the controller:
>
>$scope.data = { showFinalized : false };
>
>Then ng-bind to "data.showFinalized".
>
>(there isn't anything special about the name "data" - you could name this var anything you'd like).

I'll try to make that adjustment, thanks. It's weird that it was working fine before and then all of the sudden stopped working today...
If it's not broken, fix it until it is.


My Blog
Previous
Reply
Map
View

Click here to load this message in the networking platform