Skip to content

Latest commit

Β 

History

History
85 lines (70 loc) Β· 2.9 KB

File metadata and controls

85 lines (70 loc) Β· 2.9 KB

Ultimate React Project

A production-ready React application with modern tooling and best practices following a comprehensive feature-based architecture.

πŸ› οΈ Tech Stack

  • React 18 + TypeScript
  • Vite - Fast build tool
  • React Router DOM - Client-side routing
  • Redux Toolkit - State management
  • TanStack Query - Server state management
  • React Hook Form + Zod - Form handling and validation
  • shadcn/ui - Beautiful, accessible components
  • Framer Motion - Smooth animations
  • Tailwind CSS - Utility-first styling
  • Axios - HTTP client
  • Vitest - Testing framework

πŸ—οΈ Project Structure

src/
β”œβ”€β”€ app/                     # App-level configuration
β”‚   β”œβ”€β”€ store/              # Redux store setup
β”‚   β”œβ”€β”€ providers/          # React providers
β”‚   β”œβ”€β”€ router/             # Routing configuration
β”‚   └── config/             # App constants and configuration
β”œβ”€β”€ shared/                  # Shared across modules
β”‚   β”œβ”€β”€ components/         # Reusable UI components
β”‚   β”œβ”€β”€ hooks/              # Custom React hooks
β”‚   β”œβ”€β”€ services/           # API and external services
β”‚   β”œβ”€β”€ utils/              # Utility functions
β”‚   └── types/              # TypeScript type definitions
β”œβ”€β”€ features/               # Feature modules
β”‚   β”œβ”€β”€ auth/               # Authentication feature
β”‚   β”œβ”€β”€ dashboard/          # Dashboard feature
β”‚   └── users/              # User management feature
β”œβ”€β”€ assets/                 # Static assets
β”œβ”€β”€ styles/                 # Global styles and themes
β”œβ”€β”€ lib/                    # External library configurations
β”œβ”€β”€ test/                   # Testing utilities and setup
└── docs/                   # Documentation

πŸš€ Getting Started

# Install dependencies
npm install

# Copy environment variables
cp .env.example .env

# Start development server
npm run dev

πŸ“ Available Scripts

  • npm run dev - Start development server
  • npm run build - Build for production
  • npm run preview - Preview production build
  • npm run lint - Run ESLint
  • npm run test - Run tests
  • npm run test:ui - Run tests with UI
  • npm run test:coverage - Run tests with coverage
  • npm run type-check - Run TypeScript type checking

🎯 Features

  • βœ… Feature-based architecture for scalability
  • βœ… Type-safe routing with React Router
  • βœ… Redux Toolkit for predictable state management
  • βœ… TanStack Query for server state and caching
  • βœ… Form validation with React Hook Form + Zod
  • βœ… Beautiful, accessible UI components with shadcn/ui
  • βœ… Smooth animations with Framer Motion
  • βœ… Dark/Light theme support
  • βœ… Comprehensive testing setup with Vitest
  • βœ… TypeScript path aliases for clean imports
  • βœ… Production-ready build configuration

πŸ”§ Architecture Principles

Feature-Based Structure