Friday, March 6, 2020

Angular 8 & 9 Features and Advantages


Angular is a platform and framework for building single-page client applications in HTML and TypeScript. Angular is written in TypeScript.

The advantages of using the angular are listed below

    1)Two way data binding, using banana in a box syntax “[(ngModel)]”
    2)Dependency injection
    3)Uses MVC pattern
    4)Supports animations and event handler
    5)Provides client server communication
    6)Custom directives creation
    7)Community support for development queries

The disadvantages are

    1)Complex single page Applications (SPA)
    2)Dynamic nature of applications
    3)Learning of angular is difficult


New Futures in Angular 8 are

    1) AOT compiler – AOT is default rendering engine – for compilation
IVY compiler preview is introduced. The AOT compilation step only ran when we executed using   the production flag

ng build –prod.

    2) Bezel engine

When you use Angular CLI build commands such as ng build and ng serve, Bazel is used behind the scenes.

   3) Lazy loading

For large apps with lots of routes, consider lazy loading — a design pattern that loads NgModules as needed. Lazy loading helps keep initial bundle sizes smaller, which in turn helps decrease load times.

   4) Web workers
   5) Support for Typescript 3.4 and 3.5

New Futures in Angular 9 are

1) Angular Ivy  Engine – is the default rendering engine – for compilation
2) Support only Typescript 3.7 or greater  - Typescript 3.4 and 3.5 are no longer supported

  - Version 9 is more about changes to the framework, not the code that we wrote
  - Ivy introduces more comprehensive type-checking within templates.
  - AOT compilation with Ivy is faster and should be used by default.
  - Angular 9 brings AOT to the dev build, too! The Ivy compiler makes our builds much    faster in build.

ng serve

  - Ivy, the default compiler that can reduce bundle size, improve debugging, and much more.
  - For building the application, aot: true, is set to true.i.e, the default compilation is using IVY along with aot.

  Angular.json Contains the below configurations for aot in build section




No comments: