TwanoO67 / bootstraping-ngx-admin-lte

Angular2,4,6 project with AdminLTE dashboard template (using angular, angular-cli and ngx-admin-lte ) Formerly called 'ng2-admin-lte'.
463 stars 220 forks source link

Problem with AOT compilation #86

Open TwanoO67 opened 7 years ago

TwanoO67 commented 7 years ago

The AOT compilation process fail with error:

ERROR in Error encountered resolving symbol values statically. Function calls are not supported. Consider replacing the function or lambda with a reference to an exported function (position 194:50 in the original .ts file), resolving symbol NgModule in /home/twanoo/GIT/bootstraping-ngx-admin-lte/node_modules/ngx-admin-lte/node_modules/@angular/core/core.d.ts, resolving symbol NgxAdminLteModule in /home/twanoo/GIT/bootstraping-ngx-admin-lte/node_modules/ngx-admin-lte/src/ngx-admin-lte.module.ts, resolving symbol NgxAdminLteModule in /home/twanoo/GIT/bootstraping-ngx-admin-lte/node_modules/ngx-admin-lte/src/ngx-admin-lte.module.ts

It's seems to come from the TranslateModule in this file: https://github.com/TwanoO67/ngx-admin-lte/blob/develop/src/ngx-admin-lte.module.ts

if someone know how to fix that, any help will be very much appreciated :)

TwanoO67 commented 7 years ago

It's seems to be related to the TranslationService but I can't investigated further...

giatuyentiensinh commented 7 years ago

I think https://github.com/TwanoO67/ngx-admin-lte/blob/develop/src/ngx-admin-lte.module.ts#L12 it should be return new TranslateHttpLoader( http, './public/assets/i18n/', '.json' );

TwanoO67 commented 7 years ago

As it's a http loading, the "public" part of the path, is not visible. So I think it should remain that way.

But I tried both ways and none of them fix the problem. ( FurtherMore I don't think than the TranslationService is working anymore [or at least, I dont see anymore the network requests that should load the dictionnaries...] )