Comparison Between Version of Angular

Download as pdf or txt
Download as pdf or txt
You are on page 1of 15

WHY ANGULAR 15, NOT ANGULAR 9?

DIFFERENCES (HISTORY & VERSION)


Angular 9 Angular 15

▪ Released Date: 6 February 2020. ▪ Released Date: 16 November 2022.

▪ Latest Version: v9.1.12 ▪ Latest Version: v15.2.9

▪ Typescript Support: v3.6 – v3.8 ▪ Typescript Support: v4.8


DIFFERENCES (PERFORMANCE)
Angular 9 Angular 15

▪ Angular 9 is a large framework which can ▪ Every new update in Angular improves
slow down the application's performance, the efficiency or performance of
especially on lower-end devices. application.
DIFFERENCES (LINES OF CODE-LOC)
Angular 9 Angular 15

▪ Increasing LOC in source code because ▪ Decreasing LOC because of new


of old ways of implementation. shorthand code ways in Methods/Suites/
Packages/Wrappers etc.
DIFFERENCES (BUILD SIZE)
Angular 9 Angular 15

▪ Build size is large because of old ▪ Enhanced compilation to minimize the


compilation ways (compiler). build size.
DIFFERENCES (STRICT MODE)
Angular 9 Angular 15

▪ No Strict Mode in angular.json. ▪ Strict Mode is available in angular.json.

Strict Mode:

Angular CLI creates all new workspaces and projects with strict mode enabled.
Strict mode improves maintainability and helps you catch bugs ahead of time. Additionally, strict
mode applications are easier to statically analyze.
DIFFERENCES (DEBUGGING)
Angular 9 Angular 15

▪ Debugging can be challenging as ▪ Stack Traces for debugging:


Angular 9 uses a complex set of
components and services that can make Developer can trace the code efficiently
it difficult to isolate the source of the by simply using the Stack Trace. This
issue. feature contributes when facing any error
and helps find where this error is
experienced or found.
DIFFERENCES (OVER-ENGINEERING)
Angular 9 Angular 15

▪ Angular 9 can sometimes lead to over- ▪ See the Advantages of Angular 15.
engineering of application. But this can
be resolved using proper planning,
development, testing.

Over-Engineering:

Over-engineering is the act of designing a product or providing a solution to a problem in an


elaborate or complicated manner, where a simpler solution can be demonstrated to exist with the
same efficiency and effectiveness as that of the original design.
Using the standalone components allows working in
synchronization with the HTTP with client routers, ADVANTAGES
angular elements, and many more.
OF ANGULAR
Also, bundlers can reduce the bundle size by around 15
11% by removing the unused features from the router at New Standalone API
the build time. System.
The Angular image directive lazy loads non-critical
images by default and only eagerly loads images ADVANTAGES
specially marked as priority. This ensures that most
images exhibit optimal loading behavior. OF ANGULAR
15
The “NgOptimizedImage” directive makes it easy to New Image Directive.
adopt performance best practices for loading images.
It makes the Router even simpler and further reducing
the boilerplate, the Router now auto-unwraps default ADVANTAGES
exports with lazy loading, further contributing to
reducing the code. OF ANGULAR
15
The Router Unwraps
Default Imports
The Angular Language Service provides code editors
with a way to get completions, errors, hints, and ADVANTAGES
navigation inside Angular templates. It works with
external templates in separate HTML files, and also with OF ANGULAR
in-line templates.
15
Automatic Language
Service Import
It allows us to create custom components for our
applications based on other components we create. This ADVANTAGES
means we can reuse our components in multiple places
without reinventing the wheel every time. OF ANGULAR
15
MDC Based Component
They allow us to load the right modules at runtime
without the need to depend on a webpack loader or ADVANTAGES
something like WebPack. A module loader can be used
as a hook into any build system you have, such as Babel, OF ANGULAR
Webpack, or Gulp.
15
Module Loaders
CONCLUSION
▪ Summary:
There are many features of Angular that make it an excellent choice for web apps development.
The Angular team releases new versions constantly and announces more and more performance
improvements, long-term support, backward compatibility, critical fixes and more. In short, Angular
will continue to evolve and enhance.

▪ Assumption:
Lets assume after 2-3 yrs, a new revolution will be going to happen in Web Development (because
of AI) then what are you going to do with your app source code/build developed in angular 9 (6
feb,2020). Will the angular community help/support you to migrate the old source code which may
be deprecated. I mean migrating or upgrading old versions/build/source code will lead to more
efforts/budgets/time and much more. It is better to adapt latest technology to avoid future
technology crisis.
Eg: Even Apple removes / discontinues its iPhone 11 when iPhone 14 released from the official site.

You might also like