Solid reference for React with TypeScript that covers the stuff you actually need: component prop patterns, event handler typing, generic components, and hooks. The React 19 coverage is the standout here, walking through the ref as prop change, useActionState replacing useFormState, and the new use() hook for unwrapping promises. Also includes server components and type-safe routing with TanStack Router and React Router. Useful when you're tired of fighting with event types or need to remember the right way to type useRef for DOM elements versus mutable values. More practical patterns than theory.

skills.sh installs
498
GitHub stars
33.2K
last updated
Aug 21, 2026

Install

$ npx -y skills add davila7/claude-code-templates --skill react-dev --agent claude-code

Installs into .claude/skills of the current project.

Files

React TypeScript

Type-safe React = compile-time guarantees = confident refactoring.

<when_to_use>

  • Building typed React components
  • Implementing generic components
  • Typing event handlers, forms, refs
  • Using React 19 features (Actions, Server Components, use())
  • Router integration (TanStack Router, React Router)
  • Custom hooks with proper typing

NOT for: non-React TypeScript, vanilla JS React

</when_to_use>

<react_19_changes>

React 19 breaking changes require migration. Key patterns:

ref as prop - forwardRef deprecated:

// React 19 - ref as regular prop
type ButtonProps = {
  ref?: React.Ref<HTMLButtonElement>;
} & React.ComponentPropsWithoutRef<'button'>;

function Button({ ref, children, ...props }: ButtonProps) {
  return <button ref={ref} {...props}>{children}</button>;
}

useActionState - replaces useFormState:

import { useActionState } from 'react';

type FormState = { errors?: string[]; success?: boolean };

function Form() {
  const [state, formAction, isPending] = useActionState(submitAction, {});
  return <form action={formAction}>...</form>;
}

use() - unwraps promises/context:

Sponsors

Details

Repository
github.com/davila7/claude-code-templates
Categories
Frontend Development, Backend & APIs
First seen
Jun 3, 2026

More from davila7/claude-code-templates

All 618
1manutej avatarnextjs-developmentmanutej/luxor-claude-marketplaceComprehensive Next.js development skill covering App Router, Server Components, data fetching, routing patterns, API routes, middleware, and full-stack Next.js 473skills.sh installs
2manutej avatarreact-developmentmanutej/luxor-claude-marketplaceComprehensive React development with hooks, components, state management, context, effects, and performance optimization based on official React documentation468skills.sh installs
3pproenca avatarzustandpproenca/dot-skillsZustand state management best practices for React applications. Use when writing, reviewing, or refactoring Zustand stores to ensure optimal performance and mai453skills.sh installs
4suryavirkapur avatarsolidjssuryavirkapur/skillsSolidJS framework development skill for building reactive web applications with fine-grained reactivity. Use when working with SolidJS projects including: (1) C452skills.sh installs
5davila7 avatarnextjs-supabase-authdavila7/claude-code-templatesExpert integration of Supabase Auth with Next.js App Router Use when: supabase auth next, authentication next.js, login supabase, auth middleware, protected rou410skills.sh installs
6questfortech-investments avatarreact-vite-expertquestfortech-investments/claude-code-skillsComplete React + Vite expertise for building optimized, scalable applications. Covers project architecture, folder structure, component patterns, performance op405skills.sh installs