Angular
Components, templates, dependency injection, signals, RxJS, forms, routing, HTTP, state management, testing, and the production concerns of shipping an Angular application — the framework itself, not the TypeScript it's written in (`typescript`) or the JavaScript underneath that (`javascript`). Sixty-two lessons.
What Angular is, and how it's put togetherAngular's philosophy as a full platform, its core packages, and where it sits next to React and Vue.The CLI, project anatomy, and standalone bootstrappingWhat `ng new` actually generates, and how a modern Angular app boots without an `app.module.ts`.NgModules — the legacy architectureWhat NgModule did, why Angular moved away from it, and how to read a codebase that still uses it.Angular versioning and staying currentHow Angular's release cadence and semantic versioning work, and how `ng update` moves a real app across major versions.Component basics and the @Component decoratorWhat the @Component decorator actually does, and the metadata every component carries.Interpolation and property, attribute, class, and style bindingThe four ways an Angular template connects to component data, and when to reach for each one.Event binding and template reference variablesHow a template reacts to user input, and how to grab a handle on an element without leaving the template.Component lifecycle hooksThe fixed sequence of moments every component passes through, and which hook to use for each one.View encapsulation and component stylingHow Angular scopes a component's CSS by default, the three encapsulation modes, and why `::ng-deep` is a trap.ng-template, ng-container, and ngTemplateOutletThe three building blocks behind every conditional and reusable template fragment in Angular.Built-in control flow: @if, @for, and @switchAngular's native control-flow blocks, and why they replaced the structural directives they look nothing like.Legacy structural directives: *ngIf, *ngFor, *ngSwitchHow to read the asterisk-prefixed directive syntax you'll meet in any Angular codebase older than the control-flow blocks.Attribute directives and building your own`ngClass`/`ngStyle` as attribute directives, and how to write a custom one with host bindings and listeners.Built-in and custom pipesTransforming data at the point it's displayed, and the pure/impure distinction that decides how often a pipe reruns.The async pipeSubscribing to an observable or promise directly in a template, with Angular handling the unsubscription.Inputs and outputs: @Input, @Output, and EventEmitterHow a parent passes data down to a child component, and how a child reports back up.Signal inputs, model inputs, and outputsThe input(), model(), and output() functions that replace @Input()/@Output() with signal-based component APIs.Content projection with ng-contentLetting a parent supply markup a child component renders inside its own template — single- and multi-slot.ViewChild, ContentChild, and signal queriesReaching into a component's own template or projected content from its TypeScript code.Dependency injection fundamentals and the injector treeWhat problem dependency injection solves, and the two ways to ask Angular's injector for something.Providers and injection tokensThe four ways to tell an injector what to hand over, and InjectionToken for the things that aren't classes.Hierarchical and scoped injectorsWhy providedIn: 'root' isn't the only option, and how a component-level provider creates its own, scoped instance.Services as shared stateUsing a singleton service as the place two unrelated components meet, instead of routing everything through inputs and outputs.Signals, computed values, and effectsThe signal(), computed(), and effect() primitives Angular's reactivity model is now built around.Change detection and zone.jsHow Angular has historically known when to re-check the DOM — and why that required patching the browser's own async APIs.OnPush change detectionOpting a component out of the default full-tree check, and the immutability discipline that makes it safe.Zoneless AngularRunning Angular without zone.js, now that signals give the framework a precise way to know what changed.Observable fundamentals for AngularWhat an observable actually is, and where Angular itself already relies on them before you write a line of RxJS.Common RxJS operators in Angularmap, switchMap, and debounceTime through a real Angular use case: a typeahead search box.Subjects and multicastingSubject and BehaviorSubject as both an observable and an observer at once — the building block of a hand-rolled event bus or state service.Subscription management and takeUntilDestroyedWhy a manual .subscribe() call is a liability the moment you forget to clean it up, and the tools that remove the need to remember.Interop between signals and observablestoSignal() and toObservable() bridge Angular's two reactive systems — and when to reach for which one in the first place.Template-driven formsBuilding a form with ngModel directly in the template — and when that's genuinely the better choice over reactive forms.Reactive forms fundamentalsFormControl, FormGroup, and FormBuilder — constructing a form's structure explicitly in TypeScript instead of implicitly in the template.Form validation: built-in and custom validators, and FormArrayAttaching validators to a reactive form, writing your own, catching cross-field errors, and handling a dynamic list of controls.Typed reactive formsStrictly typed FormGroup<T> — and what untyped reactive forms were quietly letting slip past the compiler.Router fundamentals and route configurationThe Routes array, RouterOutlet, RouterLink, and provideRouter — the minimum setup every routed Angular app needs.Route parameters and query parametersReading :id-style route segments and ?key=value query strings through ActivatedRoute — snapshot versus reactive.Child routes and layout compositionNesting routes inside a parent's own layout, and using named outlets to render more than one routed region at once.Route guards and resolversFunctional guards that control whether a navigation is allowed, and resolvers that fetch data before a route activates.Lazy loading routes and componentsloadComponent and loadChildren — shipping a smaller initial bundle by only downloading a route's code when it's actually visited.HttpClient fundamentalsprovideHttpClient, typed requests, and the observables HttpClient hands back for every call.HTTP interceptorsIntercepting every outgoing request and incoming response to handle auth tokens, logging, and errors in one place.Error handling and retry strategiescatchError and retry for HTTP calls, and centralizing error handling in one place instead of per call site.Caching HTTP datashareReplay for avoiding duplicate requests, and why that's a different, narrower problem than full state-management caching.Component state and services as stateWhen local component state is enough, and when lifting it into a shared service — with signals as the container — is the right next step.Introduction to NgRxActions, reducers, selectors, and effects — the Redux pattern NgRx brings to Angular, and why it trades simplicity for structure.The NgRx SignalStore@ngrx/signals' SignalStore — NgRx's own structure, rebuilt around signals instead of the classic actions-and-reducers pipeline.Unit testing components with TestBedConstructing a component in isolation for testing, querying its rendered DOM, and manually triggering change detection.Testing services and HTTPTesting an injectable service in isolation, and HttpTestingController for asserting on and responding to HTTP calls without a real network.Test runners: from Karma to VitestAngular's shift away from Karma, through a Jest-era waypoint, to Vitest as the current default application test builder.End-to-end testingTesting a real, running Angular app from the outside with Playwright or Cypress — and what unit tests were never meant to cover.track and list rendering performanceWhy @for requires a track expression, and *ngFor's trackBy before it — both answer the same identity question.Deferrable views: the @defer blockLazily rendering a chunk of template based on a trigger, with built-in placeholder, loading, and error states.Server-side rendering and hydrationRendering an Angular app's first paint on the server, and handing off to the client without throwing that work away.Bundle size and build optimizationThe esbuild/Vite-based application builder, how lazy loading shapes your bundles, and reading what's actually in them.Angular animationsThe @angular/animations package's trigger/state/transition model, and the newer native-CSS alternative to it.InternationalizationAngular's built-in $localize/locale-build i18n pipeline, versus runtime translation libraries like ngx-translate and Transloco.Accessibility in AngularAngular's built-in ARIA directives and the CDK's a11y utilities — making a dynamic UI usable without a mouse or without sight.Security: XSS, sanitization, and CSPAngular's built-in DOM sanitization, the bypassSecurityTrust escape hatches, and Content-Security-Policy considerations for a real app.Angular Material and component librariesWhat Material and the CDK each actually provide, and the real decision between adopting a component library and building your own.PWA service workers and Nx monoreposTurning an Angular app into an installable, offline-capable PWA with @angular/pwa, and organizing several Angular projects in one Nx workspace.
Fundamentals
- What Angular is, and how it's put togetherAngular's philosophy as a full platform, its core packages, and where it sits next to React and Vue.
- The CLI, project anatomy, and standalone bootstrappingWhat `ng new` actually generates, and how a modern Angular app boots without an `app.module.ts`.
- NgModules — the legacy architectureWhat NgModule did, why Angular moved away from it, and how to read a codebase that still uses it.
- Angular versioning and staying currentHow Angular's release cadence and semantic versioning work, and how `ng update` moves a real app across major versions.
Components and templates
- Component basics and the @Component decoratorWhat the @Component decorator actually does, and the metadata every component carries.
- Interpolation and property, attribute, class, and style bindingThe four ways an Angular template connects to component data, and when to reach for each one.
- Event binding and template reference variablesHow a template reacts to user input, and how to grab a handle on an element without leaving the template.
- Component lifecycle hooksThe fixed sequence of moments every component passes through, and which hook to use for each one.
- View encapsulation and component stylingHow Angular scopes a component's CSS by default, the three encapsulation modes, and why `::ng-deep` is a trap.
- ng-template, ng-container, and ngTemplateOutletThe three building blocks behind every conditional and reusable template fragment in Angular.
Control flow, directives, and pipes
- Built-in control flow: @if, @for, and @switchAngular's native control-flow blocks, and why they replaced the structural directives they look nothing like.
- Legacy structural directives: *ngIf, *ngFor, *ngSwitchHow to read the asterisk-prefixed directive syntax you'll meet in any Angular codebase older than the control-flow blocks.
- Attribute directives and building your own`ngClass`/`ngStyle` as attribute directives, and how to write a custom one with host bindings and listeners.
- Built-in and custom pipesTransforming data at the point it's displayed, and the pure/impure distinction that decides how often a pipe reruns.
- The async pipeSubscribing to an observable or promise directly in a template, with Angular handling the unsubscription.
Component communication
- Inputs and outputs: @Input, @Output, and EventEmitterHow a parent passes data down to a child component, and how a child reports back up.
- Signal inputs, model inputs, and outputsThe input(), model(), and output() functions that replace @Input()/@Output() with signal-based component APIs.
- Content projection with ng-contentLetting a parent supply markup a child component renders inside its own template — single- and multi-slot.
- ViewChild, ContentChild, and signal queriesReaching into a component's own template or projected content from its TypeScript code.
Dependency injection and services
- Dependency injection fundamentals and the injector treeWhat problem dependency injection solves, and the two ways to ask Angular's injector for something.
- Providers and injection tokensThe four ways to tell an injector what to hand over, and InjectionToken for the things that aren't classes.
- Hierarchical and scoped injectorsWhy providedIn: 'root' isn't the only option, and how a component-level provider creates its own, scoped instance.
- Services as shared stateUsing a singleton service as the place two unrelated components meet, instead of routing everything through inputs and outputs.
Signals and change detection
- Signals, computed values, and effectsThe signal(), computed(), and effect() primitives Angular's reactivity model is now built around.
- Change detection and zone.jsHow Angular has historically known when to re-check the DOM — and why that required patching the browser's own async APIs.
- OnPush change detectionOpting a component out of the default full-tree check, and the immutability discipline that makes it safe.
- Zoneless AngularRunning Angular without zone.js, now that signals give the framework a precise way to know what changed.
RxJS in Angular
- Observable fundamentals for AngularWhat an observable actually is, and where Angular itself already relies on them before you write a line of RxJS.
- Common RxJS operators in Angularmap, switchMap, and debounceTime through a real Angular use case: a typeahead search box.
- Subjects and multicastingSubject and BehaviorSubject as both an observable and an observer at once — the building block of a hand-rolled event bus or state service.
- Subscription management and takeUntilDestroyedWhy a manual .subscribe() call is a liability the moment you forget to clean it up, and the tools that remove the need to remember.
- Interop between signals and observablestoSignal() and toObservable() bridge Angular's two reactive systems — and when to reach for which one in the first place.
Forms
- Template-driven formsBuilding a form with ngModel directly in the template — and when that's genuinely the better choice over reactive forms.
- Reactive forms fundamentalsFormControl, FormGroup, and FormBuilder — constructing a form's structure explicitly in TypeScript instead of implicitly in the template.
- Form validation: built-in and custom validators, and FormArrayAttaching validators to a reactive form, writing your own, catching cross-field errors, and handling a dynamic list of controls.
- Typed reactive formsStrictly typed FormGroup<T> — and what untyped reactive forms were quietly letting slip past the compiler.
Routing and navigation
- Router fundamentals and route configurationThe Routes array, RouterOutlet, RouterLink, and provideRouter — the minimum setup every routed Angular app needs.
- Route parameters and query parametersReading :id-style route segments and ?key=value query strings through ActivatedRoute — snapshot versus reactive.
- Child routes and layout compositionNesting routes inside a parent's own layout, and using named outlets to render more than one routed region at once.
- Route guards and resolversFunctional guards that control whether a navigation is allowed, and resolvers that fetch data before a route activates.
- Lazy loading routes and componentsloadComponent and loadChildren — shipping a smaller initial bundle by only downloading a route's code when it's actually visited.
HTTP and data
- HttpClient fundamentalsprovideHttpClient, typed requests, and the observables HttpClient hands back for every call.
- HTTP interceptorsIntercepting every outgoing request and incoming response to handle auth tokens, logging, and errors in one place.
- Error handling and retry strategiescatchError and retry for HTTP calls, and centralizing error handling in one place instead of per call site.
- Caching HTTP datashareReplay for avoiding duplicate requests, and why that's a different, narrower problem than full state-management caching.
State management
- Component state and services as stateWhen local component state is enough, and when lifting it into a shared service — with signals as the container — is the right next step.
- Introduction to NgRxActions, reducers, selectors, and effects — the Redux pattern NgRx brings to Angular, and why it trades simplicity for structure.
- The NgRx SignalStore@ngrx/signals' SignalStore — NgRx's own structure, rebuilt around signals instead of the classic actions-and-reducers pipeline.
Testing
- Unit testing components with TestBedConstructing a component in isolation for testing, querying its rendered DOM, and manually triggering change detection.
- Testing services and HTTPTesting an injectable service in isolation, and HttpTestingController for asserting on and responding to HTTP calls without a real network.
- Test runners: from Karma to VitestAngular's shift away from Karma, through a Jest-era waypoint, to Vitest as the current default application test builder.
- End-to-end testingTesting a real, running Angular app from the outside with Playwright or Cypress — and what unit tests were never meant to cover.
Performance and rendering
- track and list rendering performanceWhy @for requires a track expression, and *ngFor's trackBy before it — both answer the same identity question.
- Deferrable views: the @defer blockLazily rendering a chunk of template based on a trigger, with built-in placeholder, loading, and error states.
- Server-side rendering and hydrationRendering an Angular app's first paint on the server, and handing off to the client without throwing that work away.
- Bundle size and build optimizationThe esbuild/Vite-based application builder, how lazy loading shapes your bundles, and reading what's actually in them.
Production concerns and ecosystem
- Angular animationsThe @angular/animations package's trigger/state/transition model, and the newer native-CSS alternative to it.
- InternationalizationAngular's built-in $localize/locale-build i18n pipeline, versus runtime translation libraries like ngx-translate and Transloco.
- Accessibility in AngularAngular's built-in ARIA directives and the CDK's a11y utilities — making a dynamic UI usable without a mouse or without sight.
- Security: XSS, sanitization, and CSPAngular's built-in DOM sanitization, the bypassSecurityTrust escape hatches, and Content-Security-Policy considerations for a real app.
- Angular Material and component librariesWhat Material and the CDK each actually provide, and the real decision between adopting a component library and building your own.
- PWA service workers and Nx monoreposTurning an Angular app into an installable, offline-capable PWA with @angular/pwa, and organizing several Angular projects in one Nx workspace.