Skip to content

Instantly share code, notes, and snippets.

@jazdw
Created March 29, 2016 23:50
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jazdw/ef6497a374cde1d9d0b6fbd92672a28f to your computer and use it in GitHub Desktop.
Save jazdw/ef6497a374cde1d9d0b6fbd92672a28f to your computer and use it in GitHub Desktop.
scope.$watch('name', function(newValue, oldValue) {
if (newValue === undefined && newValue === oldValue) return;
scope.counter = scope.counter + 1;
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment