You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

Angular Material多选组件导入后仍报NgModule导出错误,编译失败求助

关于Angular Material多选组件编译失败的问题

我尝试添加Angular Material的multi-select组件,已修改6个文件,但项目仍无法编译,出现以下错误:

  • 错误截图1:Can't bind to 'formControl' since it isn't a known property of 'mat-select'
  • 错误截图2:'mat-select' is not a known element
  • 错误截图3:Can't bind to 'value' since it isn't a known property of 'mat-option'
  • 错误截图4:'mat-option' is not a known element
  • 错误截图5:Can't bind to 'ngModel' since it isn't a known property of 'mat-select'
  • 错误截图6:Property 'selectedOptions' does not exist on type 'ElementRef<HTMLSelectElement>'
  • 错误截图7:'mat-label' is not a known element

请问为何项目无法编译?

内容的提问来源于stack exchange,提问作者Elad Benda

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.07.06 16:23:15