A minimal, production-ready template for building React applications with Vite, TypeScript, and modern tooling.
- ⚡️ Vite - Fast build tool with HMR
- ⚛️ React 19 - Latest React with TypeScript
- 🔧 SWC - Fast TypeScript/JSX compilation
- 🧪 Vitest + Testing Library - Unit testing with React Testing Library
- 🎨 Prettier - Code formatting
- 🔍 OxLint + ESLint - Fast, comprehensive linting
- OxLint handles performance-critical rules
- ESLint handles React-specific and stylistic rules
- 📦 pnpm - Fast, disk-efficient package manager
# Install dependencies
pnpm install
# Start development server
pnpm dev
# Build for production
pnpm build
# Preview production build
pnpm previewpnpm dev- Start development serverpnpm build- Build for production (includes type checking)pnpm preview- Preview production buildpnpm test- Run tests oncepnpm test:watch- Run tests in watch modepnpm test:ui- Run tests with UIpnpm test:coverage- Run tests with coverage reportpnpm typecheck- Run TypeScript type checkingpnpm lint- Run OxLint and ESLintpnpm lint:fix- Auto-fix linting issuespnpm format- Format code with Prettierpnpm format:check- Check code formatting
├── src/
│ ├── test/
│ │ └── setup.ts # Test setup (jest-dom matchers)
│ ├── App.tsx # Main app component
│ ├── App.test.tsx # App component tests
│ └── main.tsx # App entry point
├── index.html # HTML template
├── vite.config.ts # Vite configuration
├── vitest.config.ts # Vitest configuration
├── tsconfig.json # TypeScript config (references)
├── tsconfig.app.json # TypeScript config for app code
├── tsconfig.node.json # TypeScript config for Node.js tooling
├── eslint.config.js # ESLint configuration
├── oxlintrc.json # OxLint configuration
└── .prettierignore # Prettier ignore patterns
This template uses a dual-linting approach with strict type checking enabled by default:
-
OxLint runs first with type-aware checking and handles:
- Correctness rules (syntax errors, common mistakes)
- React rules (jsx-key, no-children-prop, etc.)
- TypeScript rules (await-thenable, no-floating-promises, etc.)
- Unicorn rules (modern JavaScript patterns)
- Accessibility rules (jsx-a11y)
-
ESLint runs second with:
- OxLint-handled rules disabled (via
eslint-plugin-oxlint) - Strict type-aware TypeScript rules (
strictTypeChecked) - Stylistic type-aware rules (
stylisticTypeChecked) - React-specific rules (hooks, refresh)
- OxLint-handled rules disabled (via
This configuration provides comprehensive safety and consistency out of the box.