forms-and-validation

Build React/Next.js forms with React Hook Form and Zod validation.

Updated Jan 22, 2026
One-click install
npx skills add https://github.com/jorgeochipinti97/dublin-skills --skill forms-and-validation-jorgeochipinti97
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: forms-and-validation
Source: https://github.com/jorgeochipinti97/dublin-skills/tree/main/skills/frontend/forms-and-validation
Command: npx skills add https://github.com/jorgeochipinti97/dublin-skills --skill forms-and-validation-jorgeochipinti97

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

Build production-grade forms in React/Next.js with React Hook Form + Zod. Use for any form — login, signup, checkout, multi-step wizards, settings, dynamic field arrays, file upload, async validation (username available, VAT valid). Covers accessibility (labels, errors, aria-live), error UX, server-side validation mirroring, optimistic updates, and Server Actions integration. Pairs with frontend-foundation (Input/Select primitives) and auth-architect (signup/login forms).

Core Features & Use Cases

  • Client-side + server-side validation with a single shared schema (Zod) to ensure data integrity across contexts.
  • High-performance forms via React Hook Form's uncontrolled inputs and resolver-based validation; supports multi-step wizards, dynamic field arrays, file uploads, and async validation.
  • Accessible error UX: ARIA attributes, live regions, and keyboard-friendly focus management, with server errors mapped to fields.

Quick Start

Install dependencies and scaffold a signup form using React Hook Form and Zod to validate inputs and map server errors.

Frequently Asked Questions about forms-and-validation

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I validate React forms on both the client and server using a single schema?

You can validate React forms with a single shared Zod schema to ensure data integrity across contexts. This approach mirrors client-side and server-side validation rules, preventing duplication and ensuring consistent error handling.

What is the best way to handle accessible error UX in React Hook Form?

Accessible error UX in React Hook Form is handled using ARIA attributes, live regions, and keyboard-friendly focus management. Server errors are mapped directly to fields, ensuring screen readers announce validation issues immediately.

Can I use Server Actions with React Hook Form and Zod for form submissions?

Yes, you can integrate Next.js Server Actions with React Hook Form and Zod. This allows you to handle form submissions and perform server-side validation while maintaining the same schema used on the client.

How do I build a multi-step wizard with dynamic field arrays in React?

You can build multi-step wizards and dynamic field arrays using React Hook Form's uncontrolled inputs and resolver-based validation. This ensures high performance and supports complex form structures like checkouts and profile settings.

Does this approach support async validation for checking username availability?

Yes, React Hook Form with Zod supports async validation. You can perform asynchronous checks like username availability or VAT validation directly within the schema resolver, providing immediate feedback to users.

Why should I use uncontrolled inputs for React form validation?

Uncontrolled inputs provide high-performance React forms by reducing unnecessary re-renders during typing. Combined with resolver-based Zod validation, this approach ensures optimal UX for complex applications like dynamic field arrays.