ERROR TypeError: Cannot read properties of undefined (reading 'hasError') at template (user-profile.component.html:18:41)
我可以尝试很多想法,但我无法解决这些问题,请帮助我
表单控件上没有 hasError 属性。这就是问题所在。您正在寻找的属性称为错误。查看 https://angular.io/guide/form-validation。