ERROR Error: Uncaught (in promise): Error: Runtime compiler is not loaded Error: Runtime compiler is not loaded

441 Views Asked by At

I'm trying to use AOT compilation using ng build --prod. I don't know what I'm doing wrong.

Project Url- https://github.com/nishant1596/sampleAOT

Please Help, Thanks in advance

1

There are 1 best solutions below

0
On

I was using this form of lazyLoading -

loadChildren : ()=> import ('./home/home.module').then(m=>m.HomeModule)

instead of

loadChildren : './home/home.module#HomeModule'