在创建了UpdateOn行为之后,是否有可能更改它?它的接缝就像AbstractControl的属性是只读的:
// Cannot assign to 'updateOn' because it is a read-only property.
this.form.get('field').updateOn = 'blur';表单是在基类中创建的,现在我无法控制创建过程。
发布于 2020-12-02 09:00:41
使用setControl替换现有控件。
component.ts
this.form.setControl('field',new FormControl('', {
updateOn: 'blur'
}));https://stackoverflow.com/questions/65104431
复制相似问题