Angularjs $watch provides the latest input even when all the information was deleted -


have way around this? there better solution? simulation: http://plnkr.co/edit/2vrt8o?p=preview

context: in case inputs used filters, , information entered user used in searches. $ watches used capture information , move service in turn passes second controller.

may enough check if old , new values not equal? this:

if (newvalue != oldvalue) {    $scope.bar = newvalue; } 

plunk: http://plnkr.co/edit/ooh1am?p=preview


Comments

Popular posts from this blog

image - ClassNotFoundException when add a prebuilt apk into system.img in android -

I need to import mysql 5.1 to 5.5? -

Java, Hibernate, MySQL - store UTC date-time -