下面的代码竟然出错了:

  <mat-form-field>
        <input matInput placeholder="输入名称">
  </mat-form-field>

错误提示的莫名其妙,其实只要导入以下模块就可了:

imports: [
        MatFormFieldModule,
        MatInputModule,
    ]

 

相关文章:

  • 2021-10-01
  • 2022-12-23
  • 2021-10-19
  • 2021-11-15
  • 2021-09-14
  • 2021-11-02
  • 2021-07-15
  • 2022-12-23
猜你喜欢
  • 2022-12-23
  • 2022-12-23
  • 2021-12-19
  • 2022-12-23
  • 2022-12-23
  • 2021-07-25
  • 2021-07-17
相关资源
相似解决方案