formik-patterns — Claude Code skill: Formik forms with Yup
formik-patterns adds Formik form recipes to Claude: Yup schemas, field handlers, a submit flow and multi-step forms.
no license ★ 6,091 updated 2026-01-06
npx skills add ChrisWiles/claude-code-showcase --skill formik-patterns -a claude-codeWhat formik-patterns does
The skill hands Claude working Formik recipes. Basic setup is useFormik with a Yup validationSchema, handleChange and handleBlur wired per field, and errors shown only once a field has been touched. Schema snippets cover email, password rules, matching confirmation via yup.ref, phone numbers and numeric ranges.
Conditional rules use when. Submission goes through a GraphQL mutation with setSubmitting cleared in finally, and the edit form uses enableReinitialize plus a button gated on dirty. A getFieldProps helper spreads the right props onto a field. Multi-step flows keep the step index in useState and swap the schema per step.
The markup assumes Input, Button and VStack components with props such as onChangeText and isDisabled. Plain <input> elements mean rewriting the examples. Both formik and yup have to be in the project already.
What it helps with
- build a login form with email and password validation
- show a field error only after the user leaves the input
- check that password and confirmation match
- submit form values through a GraphQL mutation and clear the loading state
- split a long form into steps with a separate schema per step
Example prompts for the agent
- Build a signup form with
useFormikand a Yup schema for email, password and confirmation. - Rework the edit form so new values come in through
enableReinitializeand Save stays disabled untildirty. - Split the checkout into three steps, each with its own validation schema.
How to install formik-patterns
1Skills CLI (Vercel)
npx skills add ChrisWiles/claude-code-showcase --skill formik-patterns -a claude-code2Manually: put the files in place
~/.claude/skills/formik-patterns/SKILL.mdCopy the whole skill folder; for one project use .claude/skills/formik-patterns/
1Skills CLI (Vercel)
npx skills add ChrisWiles/claude-code-showcase --skill formik-patterns -a codex2Manually: put the files in place
.agents/skills/formik-patterns/SKILL.mdFor all projects use ~/.agents/skills/
1Skills CLI (Vercel)
npx skills add ChrisWiles/claude-code-showcase --skill formik-patterns -a cursor2Manually: put the files in place
.cursor/skills/formik-patterns/SKILL.mdCursor also reads .agents/skills/ and .claude/skills/
1GitHub CLI
gh skill install ChrisWiles/claude-code-showcase .claude/skills/formik-patterns2Manually: put the files in place
.github/skills/formik-patterns/SKILL.md1Skills CLI (Vercel)
npx skills add ChrisWiles/claude-code-showcase --skill formik-patterns -a gemini-cli2Platform CLI
gemini skills install https://github.com/ChrisWiles/claude-code-showcase --path .claude/skills/formik-patternsManually: put the files in place
.devin/skills/formik-patterns/SKILL.mdThe legacy .windsurf/skills/ path still works
Claude.ai
Zip the folder and upload it in Settings → Capabilities → Skills
Step by step, with commands for each platform: How to install skills in Claude Code: five ways
Questions about formik-patterns
How do I install formik-patterns in Claude Code?
Run npx skills add ChrisWiles/claude-code-showcase --skill formik-patterns -a claude-code. The skill lands at ~/.claude/skills/formik-patterns/SKILL.md.
What does formik-patterns do?
It gives Claude Formik patterns: Yup schemas, field handlers, submit handling and multi-step forms.
What does the skill need to work?
formik and yup must be installed in the project. The examples use Input, Button and VStack components, so other UI libraries need the markup adapted.