在angular中使用ngModel做双向数据绑定报错:
ERROR Error: Uncaught (in promise): Error: Template parse errors:
Can't bind to 'ngModel' since it isn't a known property of 'input'.
原因:模块中没有导入FormsModule
import {FormsModule} from '@angular/forms';
在angular中使用ngModel做双向数据绑定报错:
ERROR Error: Uncaught (in promise): Error: Template parse errors:
Can't bind to 'ngModel' since it isn't a known property of 'input'.
原因:模块中没有导入FormsModule
import {FormsModule} from '@angular/forms';
本文标题:Angular报错记录 - Can't bind to 'ngM
本文链接:https://www.haomeiwen.com/subject/dzsbkftx.html
网友评论