World Congress 2026 Europe - Virtual Stage Jul 2, 2026 Session details

Angular Lifecycle Hooks: The Right Hook for the Right Job

Ankita Sood

Are you still relying on legacy lifecycle hooks out of habit? Discover how Angular v22's signal APIs let you build fully reactive components using zero explicit hooks.

Pause
Mute Enter Fullscreen
#1 about 4 min

Reevaluating Angular lifecycle hooks in the signal era

The stabilization of signals provides opportunities to reconsider old boilerplate component patterns.

#2 about 2 min

The four phases of Angular component lifecycles

Understanding creation, change detection, rendering, and destruction provides a framework for hook selection.

#3 about 1 min

Understanding top-to-bottom component tree traversal errors

State mutations during DOM traversal trigger the dreaded expression changed after check error.

#4 about 2 min

Replacing traditional ngOnInit usage with input signals

The introduction of input signals eliminates the need to rely on initialization hooks for guaranteed input values.

#5 about 1 min

Tracking input modifications with computed instead of ngOnChanges

Developers can track previous and current input values purely through reactivity without implementing custom diffing logic.

#6 about 2 min

Moving from template lifecycle hooks to modern render APIs

New rendering functions provide a server-safe approach to handling projected content and component views.

#7 about 2 min

Simplifying component cleanup operations with the DestroyRef injection

Injecting a destruction reference allows cleanup logic to be colocated directly next to the relevant resource.

#8 about 2 min

Shifting to intent-based derivations over imperative lifecycle callbacks

Signal APIs perform the heavy lifting that previously required precise knowledge of exact callback timings.

#9 about 1 min

Avoiding effects in favor of computed and linked signals

Lazily evaluated computed functions should handle state derivations instead of relying on side-effect APIs for synchronization.

#10 about 2 min

Utilizing app-scoped render functions for server-safe DOM manipulation

Functions like afterNextRender run after DOM commitment without executing on the server or binding to component scopes.

#11 about 1 min

Preventing layout thrashing with distinct read and write render phases

Separating DOM measurements from modifications prevents the browser from repeatedly recomputing layout structures.

#12 about 2 min

Building zero-lifecycle components using derivations and OnPush change detection

Eliminating imperative hooks entirely leads to cleaner components that maximize the performance benefits of signals.

#13 about 3 min

Applying a practical framework for selecting the correct component hook

A categorized framework helps developers match specific technical requirements to the appropriate state derivation or lifecycle API.

#14 about 3 min

Guiding AI coding assistants to use modern signal-based patterns

Leveraging specialized developer skills and tools prevents large language models from hallucinating outdated boilerplate syntax.

#15 about 2 min

Adopting new hooks incrementally without refactoring legacy components

Modern signal patterns should be applied to newly built features without breaking backward compatibility on existing stable code.

Matching moments

5:46 min

Origins and goals of Angular signals

Daniela Bonvini · LIVE

8:34 min

Exploring Angular component patterns and upcoming framework updates

Benedikt Starzengruber · LIVE

4:02 min

Implementing standalone APIs in modern Angular architectures

Valentine Awe · WWC 2023

3:46 min

The rise of modern component-based frameworks and modular architecture

Sasha Shynkevich · LIVE

2:36 min

Utilizing JavaScript primitives for reactivity and user interface synchronization

Michael Egger-Zikes Michael Egger-Zikes · WWC 2025

3:24 min

Introduction to building reusable Angular components

Valentine Awe · WWC 2022

Upcoming sessions on this topic

Open session

World Congress 2026 North America

Architecting AI in Angular: WebMCP, A2UI, and the Agent Experience

Ankita Sood

Sr. Principal Engineer @ Secureworks | Angular GDE

Ankita Sood
Open session

World Congress 2026 North America

Beyond Vibe Coding: An AI Builder’s Guide to Migrating 10k+ React Components

Shubham Chaurasia

Senior Software Engineer @ Meta

Shubham Chaurasia
Open session

World Congress 2026 North America

Agentic Drift: keeping pace with your agents

John Coghlan

Senior Director, Developer Advocacy at GitLab

John Coghlan
Open session

World Congress 2026 North America

Designing APIs That Survive AI Agents at Scale

Phani Pendurthi

Mastercard, Principal Software Engineer

Phani Pendurthi
Open session

World Congress 2026 North America

When Humans Stop Writing Code: Rethinking Languages, Compilers, and Responsibility

Simon Auer

Organizer of flutter vienna meetup and CEO of marqably

Simon Auer
Open session

World Congress 2026 North America

The spectrum of agentic coding: From vibe coding to high-quality software engineering

YK Sugi

Developer Experience Manager at Eventual

YK Sugi