Documentation
Templates
Overview

Templates

Copy-paste code for common React patterns.

All templates are production-ready with TypeScript, proper error handling, and accessibility built-in.

Categories

Hooks

Reusable React hooks for common functionality.

HookPurpose
useDebounceDelay value updates for search inputs
useLocalStoragePersist state in localStorage
useClickOutsideDetect clicks outside elements
useMediaQueryResponsive design with JS
useCopyToClipboardCopy text with feedback
useToggleBoolean state management

Utilities

Helper functions for common operations.

UtilityPurpose
cnMerge Tailwind classes
Date FormattingFormat dates with date-fns
Currency FormattingFormat money values
String HelpersSlugify, truncate, capitalize

Components

Production-ready React components organized by category.

Authentication

ComponentPurpose
Login FormSign in with validation
Signup FormRegistration with password rules
Auth ProviderZustand auth state + JWT

Data Display

ComponentPurpose
Data TableTanStack Table with sorting, filtering
Infinite ListInfinite scroll with TanStack Query
Search with FiltersDebounced search + URL state

User Management

ComponentPurpose
User ProfileProfile editing with avatar upload

Tech Stack

All templates use:

TechnologyPurpose
TypeScriptType safety
Tailwind CSSStyling
shadcn/uiUI primitives
React Hook FormForm handling
ZodValidation
TanStack QueryServer state

Installation

Install the base dependencies for all templates:

# Core utilities
npm install clsx tailwind-merge date-fns
 
# Forms and validation
npm install react-hook-form zod @hookform/resolvers
 
# Server state
npm install @tanstack/react-query
 
# UI components
npx shadcn-ui@latest init
npx shadcn-ui@latest add button input label card checkbox alert