brtnshrdr / angular2-image-zoom

An Angular2 Image Zoom Directive
MIT License
22 stars 16 forks source link

Anyone get this working with AOT (Ahead of Time) compile? #31

Open shentyrenty opened 4 years ago

shentyrenty commented 4 years ago

When I build with Angular 9 (ng build), I get the following error message:

ERROR in node_modules/angular2-image-zoom/index.d.ts:4:22 - error NG6002: Appears in the NgModule.imports of PGModule, but could not be resolved to an NgModule class.

This likely means that the library (angular2-image-zoom) which declares ImageZoomModule 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.

I fixed this by turning off AOT compiling in the angular.json file - change the default "aot": true to "aot": false.

My question is has anyone gotten this to work with AOT compiling turned on?

ashwinnair26 commented 4 years ago

nope.