Search
 
SCRIPT & CODE EXAMPLE
 

TYPESCRIPT

mat-form-field must contain a MatFormFieldControl

@NgModule({
    imports: [
        MatInputModule
    ],
    exports: [
        MatInputModule
    ]
})
Comment

mat-form-field must contain a MatFormFieldControl

Maybe you need to close <input> tag:

<!-- Wrong -->
<mat-form-field>
  <input matInput>
</mat-form-field>

<!-- Right -->
<mat-form-field>
  <input matInput />
</mat-form-field>
Comment

mat-form-field must contain a matformfieldcontrol checkbox

The following Angular Material components are designed to work inside a <mat-form-field>:

<input matNativeControl> & <textarea matNativeControl> (version 7 & newer)
<select matNativeControl> (version 7 & newer)
<input matInput> & <textarea matInput> (version 5 & 6)
<mat-select>
<mat-chip-list>
Comment

ERROR Error: mat-form-field must contain a MatFormFieldControl.

Make sure matInput is with lowercase 'm'
I had this error and one of my controls had MatInput instead of matInput

In any case just double check the spelling of your directives and components
Comment

PREVIOUS NEXT
Code Example
Typescript :: react functional components setstate callback 
Typescript :: nuxt "AxiosRequestConfig" 
Typescript :: c# merge two lists different types 
Typescript :: software for checking open ports of IP 
Typescript :: onblur vs valuechange 
Typescript :: type definition method typescript 
Typescript :: nest js get request response 
Typescript :: how to define array of object type in typescript 
Typescript :: react native paper menu item press not working 
Typescript :: <div 
Typescript :: typescript document.getelementbyid object is possibly null 
Typescript :: disable srr svelteKit 
Typescript :: Can only use lower 16 bits for requestCode registerForActivityResult 
Typescript :: how to permit only a few values in dbms 
Typescript :: how test with limited information 
Typescript :: Paint effects will render natively in maya software and maya hardware 2.0 render. Command will enable paint effects to render in Arnold or ay third-party render: 
Typescript :: Building a maven EAR project and specifying the configuration of which projects to include, what is the element in the plugin configuration that contains Enterprise Java Bean Projects: 
Typescript :: typescript split/partition array by condition 
Typescript :: What do HTTP requests and responses look like? 
Typescript :: Distributed Cron Job 
Typescript :: method swap to the Pair class of that swaps the first and second elements value of the pair in generic Pair class in java 
Typescript :: nativescript routerextensions navigate 
Typescript :: serenity.is custom list endpoint 
Typescript :: webots epuck line follower code 
Typescript :: scale a vector 
Typescript :: typescript Erased Structural Types 
Typescript :: what are modules in typescript 
Typescript :: products = product.object.all() python 
Typescript :: typescript cast to parent type 
Typescript :: typescript isvalidguid 
ADD CONTENT
Topic
Content
Source link
Name
6+1 =