Solution: mat-form-field must contain a MatFormFieldControl error in Angular

Angular mat-form-field must contain a MatFormFieldControl

If you are using Angular material in your project and if you have any forms in the application then you must be using Angular Material Form Field Component from MatFormFieldModule And of the common error that we usually get is while working with Angular Material Form Field is: mat-form-field must contain a MatFormFieldControl.