I am trying to lazy load a module in the following manner :
app-routing.module.ts
path: "therapist-dashboard",
canActivate: [TherapistAuthGuard],
loadChildren: () => import("./therapist/therapist-routing.module").then((m) => m.TherapistRoutingModule)
}```
But when I am trying to build using **ng build --prod**
I am getting a lot of error. I am listing a few below:
- Can't bind to 'formGroup' since it isn't a known property of 'form'. (I have already imported FormsModule and ReactiveFormsModule in therapist.module.ts)
- Can't bind to 'ngClass' since it isn't a known property of 'div'.
A lot more errors from other modules.
Please let me know how can I fix this.