Community程式設計與開發github.com

pproenca/react-hook-form

使用 useForm、useWatch、useController、useFieldArray 及 v7.55+ 的 subscribe() API 進行 React Hook Form 用戶端表單驗證的效能最佳化。適用於使用 React Hook Form 建構用戶端受控表單的場景。本技能不涵蓋 React 19 Server Actions、useActionState 或伺服器端表單處理(請改用 react-19 技能)。

react-hook-form 是什麼?

本技能專注於 React Hook Form 的用戶端表單驗證與效能最佳化,支援 useForm、useWatch、useController、useFieldArray 等核心 Hook,以及 v7.55+ 版本引入的 subscribe() API。主要適用於建構需要高效能且受控的用戶端表單,透過精準的欄位訂閱機制減少不必要的重新渲染,從而提升表單互動的流暢度。此技能明確排除 React 19 Server Actions、useActionState 及伺服器端表單處理邏輯,相關場景請參考 react-19 技能。支援 React Hook Form 7.x 以上版本,並以 React 開發者為目標使用者。

相容平台~Claude Code~Codex CLI~Cursor
Part ofReact
npx skills add https://github.com/pproenca/dot-skills/tree/main/skills/react-hook-form

Installed? Explore more 程式設計與開發 skills: steipete/bluebubbles, steipete/eightctl, steipete/blucli · View all 6 →

在你喜歡的 AI 中提問

開啟一個已預先載入此 Agent Skill 的新對話。

說明文件

react-hook-form 是做什麼的?

使用 useForm、useWatch、useController、useFieldArray 及 v7.55+ 的 subscribe() API 進行 React Hook Form 用戶端表單驗證的效能最佳化。此技能應在您使用 React Hook Form 函式庫建構用戶端受控表單時使用。此技能不涵蓋 React 19 Server Actions、useActionState 或伺服器端表單處理(請改用 react-19 技能)。

Individual skills in this repo

This repo contains 7 individual skills — each has its own dedicated page.

pproenca/clean-architecture

Clean Architecture principles and best practices from Robert C. Martin's book. This skill should be used when designing software systems, reviewing code structure, or refactoring applications to achieve better separation of concerns. Triggers on tasks involving layers, boundaries, dependency direction, entities, use cases, or system architecture.

pproenca/code-simplifier

Code simplification skill for improving clarity, consistency, and maintainability while preserving exact behavior. Use when simplifying code, reducing complexity, cleaning up recent changes, applying refactoring patterns, or improving readability. Triggers on tasks involving code cleanup, simplification, refactoring, or readability improvements.

pproenca/emilkowal-animations

Emil Kowalski's animation best practices for web interfaces. Use when writing, reviewing, or implementing animations in React, CSS, or Framer Motion. Triggers on tasks involving transitions, easing, gestures, toasts, drawers, or motion.

pproenca/nuqs

nuqs (type-safe URL query state) best practices for Next.js and other React frameworks. This skill should be used when writing, reviewing, or refactoring code that uses nuqs for URL state management. Triggers on tasks involving useQueryState, useQueryStates, search params, URL state, query parameters, nuqs parsers, limitUrlUpdates, Standard Schema, NuqsAdapter, or Next.js routing with state.

pproenca/typescript

TypeScript performance, tsconfig, type errors, async patterns — triggered when the user asks to "optimize TypeScript performance", "speed up tsc compilation", "configure tsconfig.json", "fix type errors", "improve async patterns", or encounters TS errors (TS2322, TS2339, "is not assignable to"). Also triggers on .ts, .tsx, .d.ts file work involving type definitions, module organization, or memory management. Does NOT cover TypeScript basics, framework-specific patterns, or testing.

pproenca/vitest

Vitest testing framework patterns for test setup, async testing, mocking with vi.*, snapshots, and test performance (formerly test-vitest). This skill should be used when writing or debugging Vitest tests. This skill does NOT cover TDD methodology (use test-tdd skill), API mocking with MSW (use test-msw skill), or Jest-specific APIs.

pproenca/zod

Zod schema validation best practices for type safety, parsing, and error handling. This skill should be used when defining z.object schemas, using z.string validations, safeParse, or z.infer. This skill does NOT cover React Hook Form integration patterns (use react-hook-form skill) or OpenAPI client generation (use orval skill).

相關技能