I was referring this documentation and came across the compilation concept. One can use either JIT or AOT compilation. However, I found it very brief and need to know follow
JIT (Just-in-Time Compilation)
Just-in-Time (JIT) is a type of compilation that compiles your app in the browser at runtime.
ng build ng serve
AOT (Ahead-of-Time Compilation)
Ahead-of-Time (AOT) is a type of compilation that compiles your app at build time.
ng build --aot ng serve --aot