Form Validation

How to Use Zod with Angular Signal Forms (Step-by-Step Migration)

How to Use Zod with Angular Signal Forms (Step-by-Step Migration)

December 11, 2025

You've got a form working perfectly with Reactive Forms and Zod validation, but after migrating to Signal Forms, your validation stops working. Forms submit even when invalid, and error messages disappear. The problem? Signal Forms use a completely different validation API than Reactive Forms. Angular's validateTree() function bridges this gap by translating Zod's error map into Signal Forms' validation format. This lets you keep centralized Zod schemas while still leveraging Signal Forms’ reactive state management. This step-by-step tutorial shows exactly how to wire Zod validation into Angular Signal Forms.

Signal Forms Just Got Automatic State Classes (And More)

Signal Forms Just Got Automatic State Classes (And More)

December 04, 2025

Reactive Forms automatically apply state classes like ng-touched, ng-dirty, and ng-valid, but Signal Forms initially lacked this feature. Recent Angular updates restored automatic state classes with full customization capabilities, allowing you to configure class names, add custom states, and control when classes are applied. This tutorial demonstrates how to enable and customize Signal Forms state classes, going beyond what Reactive Forms ever allowed.

I Added Cross-Field Validation with Signal Forms. This is How I Did It

I Added Cross-Field Validation with Signal Forms. This is How I Did It

November 27, 2025

Cross-field validation in Reactive Forms requires validator functions at the form level, making validation logic scattered and hard to maintain. Angular's Signal Forms API simplifies cross-field validation by allowing validators to access other field values directly using valueOf, keeping validation logic colocated with form definitions. This tutorial demonstrates how to build password confirmation validators and other cross-field validations using Signal Forms' validate() function.

Async Validation in Angular Signal Forms (Complete Guide)

Async Validation in Angular Signal Forms (Complete Guide)

November 20, 2025

Async validation in Reactive Forms requires separate validator functions, manual debouncing, and complex pending state management. Angular's Signal Forms API simplifies async validation with validateAsync() and resource(), providing built-in debouncing, pending states, and cleaner error handling. This tutorial demonstrates how to implement async validation in Signal Forms, including server-backed username checks, real-time feedback, and proper pending state management.

Your First Custom Validator in Angular Signal Forms (Step-By-Step)

Your First Custom Validator in Angular Signal Forms (Step-By-Step)

November 13, 2025

Custom validators are essential for real-world forms, but implementing them with Reactive Forms requires separate validator functions and complex error handling. Angular's Signal Forms API simplifies custom validation by integrating validators directly into form definitions with cleaner syntax and better type safety. This tutorial demonstrates how to migrate custom validators from Reactive Forms to Signal Forms, showing how the new API makes validation logic more maintainable and reactive.