I get the following error when I execute ng serve:
ERROR in node_modules/@angular/forms/forms.d.ts:1616:22 - error NG6002:
Appears in the NgModule.imports of AppModule, but could not be resolved to
an NgModule class.
This likely means that the library (@angular/forms) which declares
FormBuilder has not been processed correctly by ngcc, or is not compatible
with Angular Ivy. Check if a newer version of the library is available, and
update if so. Also consider checking with the library's authors to see if
the library is expected to be compatible with Ivy.
1616 export declare class FormBuilder {
~~~~~~~~~~~
node_modules/@angular/forms/forms.d.ts:2148:22 - error NG6002: Appears in
the NgModule.imports of AppModule, but could not be resolved to an NgModule
class.
This likely means that the library (@angular/forms) which declares
FormGroup has not been processed correctly by ngcc, or is not compatible
with Angular Ivy. Check if a newer version of the library is available, and
update if so. Also consider checking with the library's authors to see if
the library is expected to be compatible with Ivy.
2148 export declare class FormGroup extends AbstractControl {
~~~~~~~~~
I tried deleting the node_modules folder and re-installing it. I tried
updating the library @angular/forms. I tried running ng build first. I
tried editting the angular.json folder with "scripts": {
"postinstall": "ngcc --properties es2015 browser module main --first-only
--create-ivy-entry-points" I tried running npm ci in the terminal. I tried
some other things that I don't remember too. I am on a Windows operating
system.
--
You received this message because you are subscribed to the Google Groups
"Angular and AngularJS discussion" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/angular/effd5564-1277-416d-8ea5-f06219b040c2o%40googlegroups.com.