I have upgraded the Angular Version to 16. Getting this error 'mat-menu' is not a known element

Discussão em 'Angular' iniciado por Ivana Dimitrova, Maio 21, 2025.

  1. I Have upgraded the Angular version to 16. I have imported the all the material modules in the app module file and I'm still facing this error for all mat elements:

    Error: src/app/ppp/quantity-tracking/distribution/distribution-list/distribution-list.component.html:35:21 - error NG8001: 'mat-menu' is not a known element:

    1. If 'mat-menu' is an Angular component, then verify that it is part of this module.
    2. If 'mat-menu' is a Web Component then add 'CUSTOM_ELEMENTS_SCHEMA' to the '@NgModule.schemas' of this component to suppress this message.

    <mat-menu #menu="matMenu" [overlapTrigger]="false">

    Continue reading...

Compartilhe esta Página