What are the different lifecycle hooks available to Components in Angular?

The below are the lifecycle hooks available in Angular. These are added by implementing the respecti ...


What are the different types of Subjects available in Angular?

* A subject is a special type of Observable which shares a single execution path among the observers ...


How to create Routing in Angular?

1. Import and add RouterModule to the modules in NgModule 2. Declare a routes array which contains ...


How can you create a transient service in Angular?

* When you register a service into DI in Angular, the services are marked Singleton. * Alternative ...


What is the difference between parseInt() and number()?

parseInt() and Number() are both used to convert a string into a number. * parseInt() parses the ...


How can you work with cookies in Angular?

To work with Cookies, we can make use of the CookieService which is a part of the ngx-cookie-service ...


What is the difference between double equals (==) and triple equals (===) ?

In JavaScript, double equal operator (==) stands for value compare. The operands on either sides are ...


What are tree shakeable providers?

When we register providers in @NgModule(), angular internally includes all those related classes in ...


What are Pure Pipes and Impure Pipes?

Pipes by default are "Pure" - they can't detect changes when a value of the primitive type or the re ...


What are Async Pipes?

Async Pipes help transforming data coming from an Observable and resolve into desired dataset. It al ...


What are Hot Observables and Cold Observables?

* Cold Observables are observables where data is produced _inside_ the Observable. It can be treated ...


What is the difference between a Component and a Directive?

__Directive:__ * Directives help in modifying the behavior of an existing DOM element or adding new ...


What is the difference between ng build and ng serve?

* ___ng build___ command builds the angular application and generates the build artifacts which are ...


What are the different Guards present in Angular?

Guards in Angular help us in controlling access to certain routes of our application, unless a crite ...


How do you create an Interceptor? It is a service or class?

We can create by implementing the _HttpInterceptor_ interface from _@angular/common/http_ package. W ...


We use cookies to provide you with a great user experience, analyze traffic and serve targeted promotions.   Learn More   Accept