Set individual input element to ng-untouched

I know that there is a function $ setPristine () for a form element, is there an equivalent if I want one to set ng-pristine tags of one element, such as <input> ?

+2
source share
1 answer

The concept of pristine refers to the form as a whole, and not to the individual elements. An untouched form is one that has not yet been changed, while a dirty form is one that has been changed. The semantics of the flag of an input element that is not associated with the form as untouched, and for input elements in the form, the grandfather flag applies exclusively to the form.

+5
source

Source: https://habr.com/ru/post/1212304/


All Articles