Reputation: 38
Please suggest if PrimeNG version-9 is only version compatible with Angular 9 IVY compiler? I upgraded my project from Angular 7 to 9 and PrimeNG 7.1.3 .I tried ng serve which works fine but ng-build --prod throws error as below ( Just providing one example but almost all the PrimeNG Modules the same error) . Kindly advise what is the full command to use ngcc to make it work or only PrimeNG-9 installation is the solution?
node_modules/primeng/components/scrollpanel/scrollpanel.d.ts:34:22 - error NG6002: Appears in the NgModule.imports of MetricsModule, but could not be resolved to an NgModule class.
This likely means that the library (primeng/scrollpanel) which declares ScrollPanelModule 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.
Upvotes: 1
Views: 3558
Reputation: 101072
Yes, if you want to use Angular 9 you have to upgrade your PrimeNG version, too.
The current stable version is v9.1.2.
It's not only about the new compiler, but PrimeNG also uses stuff of the Angular API that get deprecated so you should always use the PrimeNG version that fits your Angular version.
I use Angular since version 2 and PrimeNG since version 4 and mixing major versions never worked.
Upvotes: 2