conform

Implement type-safe form validation in Remix with Conform and Zod.

1|Updated Aug 7, 2024
One-click install
npx skills add https://github.com/tejovanthn/rasikalife --skill conform
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: conform
Source: https://github.com/tejovanthn/rasikalife/tree/main/.opencode/skill/conform
Command: npx skills add https://github.com/tejovanthn/rasikalife --skill conform

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This skill provides a workflow to implement accessible, type-safe form validation in Remix applications using Conform and Zod, eliminating boilerplate and reducing runtime errors.

Core Features & Use Cases

  • Progressive enhancement forms that work with or without JavaScript.
  • Type-safe validation integrated with zod schemas and Conform helpers.
  • Supports common form patterns: nested objects, file uploads, field arrays, multi-step forms, and ARIA-compliant accessibility.
  • Example use case: build a login or signup form with client-side validation and robust server-side checks.

Quick Start

Install the necessary Conform and Zod packages in a Remix project and begin wiring forms using useForm, getFormProps, and parseWithZod to validate requests.

Frequently Asked Questions about conform

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

FAQPage Schema
How do I build type-safe forms with progressive enhancement in Remix?

Type-safe forms in Remix use Conform and Zod to wire progressive enhancement, ensuring validation works across server and client even without JavaScript. This approach handles nested objects, file uploads, and multi-step flows while maintaining ARIA accessibility compliance.

Can I use Conform with Zod for server-side and client-side form validation?

Yes, Conform integrates with Zod to parse and validate form requests on the server using parseWithZod, while useForm and getFormProps enable matching client-side validation. This combination eliminates boilerplate and reduces runtime type errors.

What packages do I need to set up Conform form validation in a Remix project?

Setting up Conform form validation in a Remix project requires installing the @conform-to/react, @conform-to/zod, and zod npm packages. You need an existing Remix project environment to implement and test the forms.

Does Conform support complex form patterns like file uploads and multi-step flows?

Yes, Conform supports complex form patterns including file uploads, nested objects, field arrays, and multi-step flows. These patterns are validated across both server and client environments using Zod schemas and Conform validation helpers.

What is the best way to handle accessible form validation in Remix?

The best way to handle accessible form validation in Remix is using Conform with Zod schemas. It provides ARIA-compliant accessibility and progressive enhancement, ensuring forms remain functional and usable even when client-side JavaScript is disabled.