I am loading a form with customer data in it. When a user edits the customer data, I want to be able to track the changes so that if a user changes url, I can pop up an alert to ask the user whether they want to continue and lose their unsaved changes.
i am thinking of putting a ng-change on every input field and keep track with a $scope.counter but this is a hassle as my form is quite big.
Is this a more elegant way to solve this issue?
Thanks