Category: Angular
-
Passing Route Data as Component Input in Angular
Angular 16 is packed with many exciting features. You can read some of them here: Angular 16 Introduction What is the purpose of the Second Parameter in creating an Angular Signal? Required @Input properties in Angular In this blog post, we will learn about- Passing Route Data as Component Input, one of the features of…
-
Standalone Component – Recording of ng-India 2023 Talk
Every Angular developer must get familiar with Standalone API and should learn to build an Angular app without using any module. In India’s Largest Angular Conference, ng-India 2023, I delivered as talk on the same. watch the recording of the talk here. In the last do not forget to watch chatGPT demo. If you prefer…
-
Hello Angular 16
On 3rd May 2023, Angular 16 is launched. Some of the essential features of Angular 16 are, Read the official announcement here: https://blog.angular.io/angular-v16-is-here-4d7a28ec680d To play around, Let us start with updating to Angular 16. npm uninstall -g @angular/cli npm install -g @angular/cli@latest After upgrading to Angular 16, you can create a Standalone Angular application using…
-
What is the purpose of the Second Parameter in creating an Angular Signal?
The angular signal() function creates a signal. This function takes two input parameters. By default, Angular executes the code of effect() even if the signal is set or updated with the same value. How can we avoid that? By leveraging the second parameter of the signal() function. Let us first understand the problem statement…
-
How to check the status of an Angular Reactive Form’s Control
Sometimes, you may have a requirement to do something when the status of an Angular form control changes. For example, you have a Login Form, and when the status of the Email control changes from valid to invalid and vice versa, you need to perform some actions. In this post, let us see how we…
-
How to Lazy and Dynamically Load a Component in Angular
There are three ways you can use a component in an Angular app. However, this article focuses on loading a component dynamically and lazily. The main advantage of lazily loading a component is reducing the initial bundle size and only downloading the component in the browser when required. Let us say that you have a…
-
Required @Input properties in Angular
Angular 16 adds a new future of making an @Input() decorated property REQUIRED, which means that to use that component, the value of the required property has to be passed. To Understand it, let us assume that you have a component named ProductComponent with @Input() decorated properties as shown below, We are using ProductComponent inside…