What problem does it solve?
This Skill helps you avoid fragile form handling by providing consistent patterns for collecting user input, validating it, and rendering accessible form controls.
Core Features & Use Cases
- Core Setup with react-hook-form: Standardizes field registration, submission handling, and common utilities like reset, watch, and setValue.
- Validation Rules & Error Display: Provides required, min/max length, regex pattern, custom validation, and conditional validation examples (e.g., email, phone, URL, password rules).
- shadcn/ui Form Components Patterns: Shows how to integrate react-hook-form with shadcn/ui Form wrappers for better accessibility and consistent UI.
- Form Submission to CMS: Demonstrates saving form submissions into a CMS collection (e.g., creating a contact-submissions record) and resetting the form afterward.
- Input Component Patterns: Covers common UI controls like Input, Textarea, Select, Checkbox, RadioGroup, and Switch.
Quick Start
Use this skill to implement a contact form with react-hook-form validation and shadcn/ui components that saves submissions to your CMS and resets the form after success.