更新时间:2023-10-17 11:36:34
有一个拉取请求正在等待添加 https://github.com/angular/angular/pull/6679
另请参阅此相关问题 https://github.com/angular/angular/issues/4933
通常使用的解决方法是重新创建表单。
After submitting the form, the pristine
state of the input is still "false". I don't know how to reset the pristine
state to be true. In Angular 1, I would use the $setPristine
function.
There is a pull request waiting to be added https://github.com/angular/angular/pull/6679 See also this related issue https://github.com/angular/angular/issues/4933
The usually used workaround is to recreate the form.