1.

What is difference between JIT and AOT in Angular 6?

Answer»
JITAOT
Loads the APPLICATION slower than AoT since it needs to compile the application when running for the first timeLoads the page more quickly than the JiT compilation
It downloads the compiler and COMPILES the application before displaying it.It doesn't want to download the compiler since AoT already compiles the code when building the application
Since the code includes the compiler code also the bundle size will be higher.Since it created fully compiled code and its optimized so it bundles size will be half the bundle size compiled by JiT
Suitable in DEVELOPMENT modeSuitable in the case of production
Following command use JiT ng build, ng serveFollowing command use AoT ng build --aot, ng serve --aot, ng build -- prod
Template binding ERRORS can be viewed at the time of displaying the application.Template binding errors are shown at the time of building.


Discussion

No Comment Found