Here is the method I am currently working with:
wordFormDirty = (): boolean => {
var self = this;
angular.forEach(self.word.wordForms, function (wf, key) {
var wordFormNgForm = 'wordFormNgForm_' + wf.wordFormId
if (!self[wordFormNgForm].$pristine) {
return true;
}
});
return false;
};
I have noticed that this method never returns true. Any suggestions on how to modify it so that a form that is not pristine will cause the wordFormDirty() method to return true?