Git Tutorial

Using Various HTML Elements

Using Input Elements Adding Text Input Modify the src/app/app.component.html file: In src/app/app.component.ts: Using Combo Box (Dropdown) Adding a Combo Box In src/app/app.component.ts: Using Checkboxes Adding a Checkbox In src/app/app.component.ts: Using Option Buttons (Radio Buttons) Adding Radio Buttons In src/app/app.component.ts: Using Tables Displaying a Static Table Dynamic Table with Angular In app.component.ts: In app.component.html: Using Buttons […]

Using Various HTML Elements Read More »

Git Tutorial

Multiple Components

Angular applications are built using components, which are the building blocks of the framework. A component in Angular controls a portion of the user interface and consists of a TypeScript class, an HTML template, and an optional CSS stylesheet. When building large applications, it’s common to divide the app into multiple components for better organization

Multiple Components Read More »

Git Tutorial

TypeScript Tutorial

TypeScript is a strongly-typed superset of JavaScript that enables developers to write more robust and maintainable code. This tutorial covers key TypeScript concepts with examples. Data Types TypeScript provides various data types for type safety. Example: Operators Operators perform operations on variables and values. Example: Arrays TypeScript arrays can hold a collection of items. Example:

TypeScript Tutorial Read More »

Git Tutorial

Angular Lifecycle Hooks

Angular lifecycle hooks allow developers to tap into specific moments in a component or directive’s lifecycle, enabling actions such as initialization, change detection, or cleanup. In this tutorial, we’ll explain each lifecycle hook and demonstrate how to use them in standalone components. 1. What Are Lifecycle Hooks? Lifecycle hooks are methods that Angular calls at

Angular Lifecycle Hooks Read More »

Git Tutorial

Angular Http Calls

This tutorial demonstrates how to use provideHttpClient in an Angular standalone app for back end calls. 1. Update App Bootstrap with provideHttpClient Update your main.ts file to include provideHttpClient. src/main.ts: import { bootstrapApplication } from ‘@angular/platform-browser’;import { provideHttpClient } from ‘@angular/common/http’;import { provideRouter, Route } from ‘@angular/router’;import { AppComponent } from ‘./app/app.component’;import { HomeComponent }

Angular Http Calls Read More »

Git Tutorial

Angular Services and Dependency Injection

This tutorial demonstrates how to create and use services in an Angular application built with standalone components. We’ll integrate a service for managing user authentication and apply dependency injection to use the service across multiple components and guards. 1. What Are Services? Services in Angular provide reusable business logic or data management across the application.

Angular Services and Dependency Injection Read More »

Git Tutorial

Angular Routing

This tutorial demonstrates how to set up routing in an Angular application using standalone components . We’ll build a simple app with a Home, About, and Contact page. 1. Setup Your Angular Application First, create a new Angular project: ng new angular-routing-tutorial// navigate to the project directorycd angular-routing-tutorial 2. Create Standalone Components Generate standalone components

Angular Routing Read More »

Git Tutorial

Reactive Forms – Using FormBuilder

Import ReactiveFormsModule In the component, you need to import ReactiveFormsModule directly inside the @Component decorator. This is how you handle form functionality in Angular without a module. Here’s how you can modify the reactive-form.component.ts: import { Component } from ‘@angular/core’;import { FormBuilder, FormGroup, ReactiveFormsModule } from ‘@angular/forms’;@Component({ selector: ‘app-reactive-form’, standalone: true, imports: [ReactiveFormsModule], templateUrl: ‘./reactive-form.component.html’,

Reactive Forms – Using FormBuilder Read More »