Now liveThe Skillselion MCP - thousands of ranked skills, loaded into your agent mid-task. No install.Get it →
aj-geddes avatar

Form Validation

  • 441 installs
  • 305 repo stars
  • Updated March 4, 2026
  • aj-geddes/useful-ai-prompts

form-validation is a useful-ai-prompts agent skill that implements React Hook Form, Formik, and Vee-Validate patterns with TypeScript for developers building accessible validated signup and checkout forms.

About

form-validation is a skill from aj-geddes/useful-ai-prompts that guides agents to implement comprehensive form validation with client-side rules, server-side synchronization, and real-time error feedback. It ships a TypeScript quick-start with LoginFormData and RegisterFormData interfaces plus a React Hook Form register and handleSubmit skeleton, and five reference guides covering React Hook Form, Formik with Yup, Vue Vee-Validate, custom validator hooks, and server-side validation integration. Developers invoke it for signup and checkout flows, multi-step forms, complex cross-field rules, and accessible error messaging—not for non-form API validation alone. The skill lives in the useful-ai-prompts collection of 260+ skills installable via npx skills add, making it a pattern library agents load when users mention form validation, react-hook-form, or real-time field errors.

  • Schema and field-level rules
  • Accessible error messaging
  • Client-server validation parity
  • Async and cross-field checks
  • Library-specific patterns (Zod, Yup, etc.)

Form Validation by the numbers

  • 441 all-time installs (skills.sh)
  • Ranked #645 of 2,245 Frontend Development skills by installs in the Skillselion catalog
  • Data as of Aug 5, 2026 (Skillselion catalog sync)
npx skills add https://github.com/aj-geddes/useful-ai-prompts --skill form-validation

Add your badge

Show developers this skill is listed on Skillselion. Paste this into your README.

Listed on Skillselion
Installs441
repo stars305
Last updatedMarch 4, 2026
Repositoryaj-geddes/useful-ai-prompts

How do you validate React forms with TypeScript?

Design client- and server-side form validation rules, error messages, accessibility, and UX patterns for signup, checkout, and data-entry flows.

Who is it for?

Frontend developers building signup, checkout, or multi-step forms who need React Hook Form, Formik, or Vee-Validate with TypeScript safety.

Skip if: Skip form-validation when you only need non-UI API request validation without client-side form components or accessibility error UX.

When should I use this skill?

User asks for form validation, react-hook-form setup, Yup schemas, real-time field errors, or server-side validation sync on submit.

What you get

Typed form components, validation schemas, error messages, and server-sync handlers

  • typed form components
  • validation schemas
  • error message patterns

By the numbers

  • Includes 5 reference guides for React Hook Form, Formik, Vee-Validate, and server sync
  • Parent useful-ai-prompts repository contains 260+ agent skills
  • Quick-start defines LoginFormData and RegisterFormData TypeScript interfaces

Files

SKILL.mdMarkdownGitHub ↗

Form Validation

Table of Contents

Overview

Implement comprehensive form validation including client-side validation, server-side synchronization, and real-time error feedback with TypeScript type safety.

When to Use

  • User input validation
  • Form submission handling
  • Real-time error feedback
  • Complex validation rules
  • Multi-step forms

Quick Start

Minimal working example:

// types/form.ts
export interface LoginFormData {
  email: string;
  password: string;
  rememberMe: boolean;
}

export interface RegisterFormData {
  email: string;
  password: string;
  confirmPassword: string;
  name: string;
  terms: boolean;
}

// components/LoginForm.tsx
import { useForm, SubmitHandler } from 'react-hook-form';
import { LoginFormData } from '../types/form';

const emailRegex = /^[^\s@]+@[^\s@]+\.[^\s@]+$/;

export const LoginForm: React.FC = () => {
  const {
    register,
    handleSubmit,
// ... (see reference guides for full implementation)

Reference Guides

Detailed implementations in the references/ directory:

GuideContents
React Hook Form with TypeScriptReact Hook Form with TypeScript
Formik with Yup ValidationFormik with Yup Validation
Vue Vee-ValidateVue Vee-Validate
Custom Validator HookCustom Validator Hook
Server-Side Validation IntegrationServer-Side Validation Integration

Best Practices

✅ DO

  • Follow established patterns and conventions
  • Write clean, maintainable code
  • Add appropriate documentation
  • Test thoroughly before deploying

❌ DON'T

  • Skip testing or validation
  • Ignore error handling
  • Hard-code configuration values

Related skills

How it compares

Pick form-validation for UI form libraries and error UX patterns; use schema-only backend validation skills when there is no React or Vue form layer.

FAQ

Which form libraries does form-validation support?

form-validation documents React Hook Form with TypeScript, Formik with Yup, Vue Vee-Validate, custom validator hooks, and server-side validation integration. Reference guides under references/ hold full implementations beyond the quick-start skeleton.

Does form-validation handle server-side validation?

Yes—form-validation includes a server-side validation integration reference guide for synchronizing client rules with backend responses and surfacing API validation errors in the UI with TypeScript-typed form data.

This week in AI coding

Five minutes, every Monday - the tools, releases and tactics for developers.

unsubscribe anytime.