No provider for ControlContainer - Angular 5

后端 未结 8 1199
萌比男神i
萌比男神i 2020-12-09 14:26

I am converting a purchased, third-party template into an Angular 5 app, and just ran into an error. I am very new to Angular 5 (I know AngularJS well however) and don\'t un

8条回答
  •  生来不讨喜
    2020-12-09 15:28

    Edit the file "app.module.ts"; change the following instruction:

    import { ReactiveFormsModule } from '@angular/forms';
    

    with the following:

    import { ReactiveFormsModule, FormsModule } from '@angular/forms';
    

    Change the following piece of code:

      imports: [
        BrowserModule,
        ReactiveFormsModule
      ],
    

    with the following:

      imports: [
        BrowserModule,
        ReactiveFormsModule,
        FormsModule
      ],
    

提交回复
热议问题