Overview
This portfolio is built with a modern, production-ready tech stack focused on performance, developer experience, and maintainability. Every technology was carefully chosen based on specific requirements and trade-offs.Core Technologies
Framework & Runtime
Next.js 16.1.5
Why Next.js?
- Built-in App Router for file-based routing
- Server Components for optimal performance
- Automatic code splitting and optimization
- Built-in image optimization
- API routes for backend functionality
- SEO-friendly with SSR/SSG support
- Excellent developer experience with Turbopack
- App Router architecture
- Dynamic Open Graph images (
opengraph-image.tsx) - Dynamic sitemap generation (
sitemap.ts) - API Routes (
api/github/route.ts) - Server and Client Components
- Dynamic imports for code splitting
React 19.2.3
Why React 19?
- Latest features and performance improvements
- Better concurrent rendering
- Improved Server Components support
- Enhanced TypeScript integration
- Action functions for forms
- Hooks (useState, useEffect, useMemo, useCallback)
- Server Components (default in Next.js 16)
- Client Components (
"use client"directive) - Dynamic component loading
Styling & UI
CSS Framework
Tailwind CSS 4 (Beta)
Tailwind CSS 4 (Beta)
package.json
- Utility-first CSS for rapid development
- Zero runtime overhead (styles extracted at build time)
- Excellent tree-shaking (unused styles removed)
- Custom design system via CSS variables
- JIT compiler for instant compilation
- New PostCSS-based architecture in v4
- Custom color scheme using CSS variables
- Font family with Geist Sans & Geist Mono
- Responsive breakpoints
- Dark mode support via CSS variables
Component Libraries
Radix UI
Why Radix UI?
- Unstyled, accessible components
- WAI-ARIA compliant
- Keyboard navigation built-in
- Focus management
- Highly customizable
- Works perfectly with Tailwind CSS
- Dialog (modals)
- Dropdown Menu (navigation)
- Label (form labels)
- Slot (polymorphic components)
shadcn/ui Pattern
Why shadcn/ui?
- Not a library, but a collection of copy-paste components
- Full ownership of component code
- Built on Radix UI + Tailwind CSS
- TypeScript-first
- Customizable without fighting abstractions
- Components live in
src/components/ui/ - Configured via
components.json - Custom variants using
class-variance-authority
Utility Libraries
| Library | Purpose | Usage |
|---|---|---|
clsx | Conditional className construction | clsx({ 'bg-red': error }) |
tailwind-merge | Merge Tailwind classes without conflicts | twMerge('p-4', 'p-2') → p-2 |
class-variance-authority | Type-safe component variants | Button sizes/variants |
Animation & Interactions
Framer Motion
Why Framer Motion?- Declarative animation API
- Spring physics for natural motion
- Gesture recognition (drag, tap, hover)
- Layout animations
- Scroll-triggered animations
- Excellent TypeScript support
- Production-optimized performance
- Page transitions
- Scroll animations
- Hover effects
- Drag interactions (
use-drag-scroll.ts) - Animated number counters
- Stagger animations for lists
Forms & Validation
React Hook Form
Why React Hook Form?
- Minimal re-renders (uncontrolled forms)
- Built-in validation
- Small bundle size (~9KB)
- Excellent TypeScript support
- Easy integration with UI libraries
- Contact form (
src/components/contact.tsx) - Form field management
- Error handling
State Management
Zustand
Why Zustand over Redux/Context?- ✅ Minimal boilerplate (no providers, actions, reducers)
- ✅ Small bundle size (~1KB)
- ✅ No Context Provider hell
- ✅ Built-in TypeScript support
- ✅ Middleware support (persist, devtools)
- ✅ Works seamlessly with React 19
- ❌ Redux: Too much boilerplate for simple state
- ❌ Context API: Performance issues with frequent updates
- ❌ Jotai: Good, but Zustand has better DX for this use case
- ❌ Recoil: Meta library with uncertain future
Icons
Icon Libraries
Icon Libraries
Lucide React (Primary)
- Modern, consistent icon set
- Tree-shakeable (only import icons you use)
- Customizable size, color, stroke
- 1000+ icons
- Access to multiple icon sets (Font Awesome, Material, etc.)
- Social media icons
- Brand logos
- Fallback for icons not in Lucide
Notifications
Sonner
Why Sonner?- Beautiful, opinionated toast notifications
- Stacking behavior out of the box
- Promise-based toasts for async operations
- Keyboard accessible
- Dark mode support
- Minimal setup required
Development Tools
TypeScript
- Strict mode enabled (
strict: true) - Path aliases (
@/*) - JSX:
react-jsx(React 19 new JSX transform) - Target: ES2017 (broad browser support)
Code Quality
ESLint
Configuration:
- Next.js recommended rules
- Prettier integration (no conflicts)
- React Hooks rules
- Accessibility checks
Build Tools & Optimization
Build Features
| Tool | Purpose | Benefits |
|---|---|---|
| Turbopack | Next.js bundler (beta) | 700x faster than Webpack |
| Bundle Analyzer | Visualize bundle size | Identify optimization opportunities |
| cross-env | Cross-platform env vars | Works on Windows/Mac/Linux |
Performance Optimizations
Implemented Optimizations
Implemented Optimizations
-
Image Optimization
- WebP format for all images
- Next.js Image component with lazy loading
- Cloudinary remote pattern for external images
-
Code Splitting
- Dynamic imports for heavy components
- Route-based splitting (automatic with App Router)
- Lazy-loaded sections on home page
-
Font Optimization
- Self-hosted Google Fonts (Geist Sans & Mono)
- Font display: swap
- Variable fonts for size reduction
-
Bundle Size
- Tree-shaking enabled
- Import only needed icons
- No moment.js (using native Date)
- Minimal dependencies
-
Caching
- Static generation where possible
- LocalStorage for user preferences
- Service worker ready (PWA potential)
Version Compatibility Matrix
| Package | Version | Compatible With |
|---|---|---|
| Next.js | 16.1.5 | React 19+ |
| React | 19.2.3 | Next.js 15+ |
| Tailwind CSS | 4.x | PostCSS 8+ |
| TypeScript | 5.x | Next.js 15+ |
| Framer Motion | 12.x | React 18-19 |
| Zustand | 5.x | React 18-19 |
| React Hook Form | 7.x | React 16.8+ |
| Zod | 3.x | TypeScript 4.5+ |
Why Not…?
Alternative Technologies Considered
Alternative Technologies Considered
Why not Vue/Svelte?
- React has the largest ecosystem and job market
- Next.js is the industry standard for React SSR
- Better TypeScript integration
- Next.js has more mature App Router
- Better build tooling (Turbopack)
- Larger community and resources
- Need more dynamic interactivity
- Zustand state management works better with React
- Component islands not needed for this use case
- Tailwind CSS has better performance (no runtime)
- Easier to maintain with utility classes
- Better tree-shaking
- Zustand is simpler for this scale
- Less boilerplate
- Better performance for small apps
- Minimal data fetching needs
- Static content from JSON files
- GitHub API called server-side only
Future Considerations
Technologies being considered for future additions:
- Vitest: Fast unit testing (replacing Jest)
- Playwright: E2E testing
- tRPC: Type-safe API calls (if backend grows)
- TanStack Query: If more data fetching is needed
- Storybook: Component documentation
Quick Reference
Install All Dependencies
Development
Dependency Categories
- Framework: Next.js 16, React 19
- Styling: Tailwind CSS 4, Radix UI
- State: Zustand
- Forms: React Hook Form + Zod
- Animation: Framer Motion
- Icons: Lucide React, React Icons
- Notifications: Sonner
- Dev Tools: TypeScript, ESLint, Prettier