This project is a modern React + Vite application. The file dev-folio-tamplate.html is provided only as a legacy reference to the original HTML version. All main development and features are implemented in React components under the src/ directory. Please use index.html and the React code for all deployment and customization.
A professional, minimal portfolio template refactored from a monolithic HTML file into a modern, scalable React + Vite application following SOLID principles and Atomic Design.
| Original | React Version |
|---|---|
| Single 500+ line HTML file | Modular component architecture (25+ files) |
Inline onclick="downloadSource()" |
Custom React hook useDownloadSource |
| Tailwind CDN (not tree-shakable) | npm Tailwind with production optimization |
Generic <div> elements |
Semantic HTML (<article>, <nav>, <main>) |
| No accessibility labels | Full ARIA labels on all interactive elements |
| No image error handling | Lazy loading + fallback UI for broken images |
✅ Issue #1: Extracted inline handlers to useDownloadSource hook
✅ Issue #2: Added semantic HTML + ARIA labels for accessibility
✅ Issue #3A: Implemented lazy loading + error boundaries for images
✅ Issue #4: Migrated to npm Tailwind for production builds
✅ Issue #5: Kept original design (no mobile menu per your request)
✅ Issue #6: Optimized font loading with preconnect
src/
├── components/
│ ├── common/
│ │ ├── MaterialIcon.jsx # Reusable icon wrapper
│ │ └── Button.jsx # Primary/Secondary button variants
│ │
│ ├── ui/
│ │ ├── BrowserChrome.jsx # Traffic light dots for mockups
│ │ └── Badge.jsx # Pill-shaped label component
│ │
│ ├── layout/
│ │ ├── Navbar.jsx # Fixed nav with glassmorphism
│ │ └── Footer.jsx # Social links footer
│ │
│ ├── cards/
│ │ └── ProjectCard.jsx # Project card with hover effects
│ │
│ └── sections/
│ ├── HeroSection/
│ │ ├── HeroSection.jsx # Main container
│ │ ├── HeroContent.jsx # Left: Text + CTAs
│ │ └── IsometricMockup.jsx # Right: 3D cards (pure CSS)
│ │
│ ├── ProjectsSection/
│ │ ├── ProjectsSection.jsx
│ │ └── SectionHeader.jsx
│ │
│ └── CodeSection/
│ ├── CodeSection.jsx
│ ├── FeaturesList.jsx
│ └── CodeTerminal.jsx
│
├── hooks/
│ └── useDownloadSource.js # Download functionality
│
├── data/
│ └── projects.js # Project data (easily editable)
│
├── utils/
│ └── constants.js # Site config & social links
│
├── styles/
│ └── global.css # Tailwind + custom CSS
│
├── pages/
│ └── Home.jsx # Main page composition
│
├── App.jsx # Root with Helmet provider
└── main.jsx # React 18 entry point
- Node.js 18+
- npm, yarn, or pnpm
# Navigate to project
cd dev-folio-react
# Install dependencies
npm install
# Start development server
npm run devThe app will open at http://localhost:3000 🎉
npm run build
npm run previewEdit src/utils/constants.js:
export const SITE_CONFIG = {
name: 'DevFolio',
tagline: 'Your Job Title Here',
author: 'Your Name',
description: 'Your bio...',
socialLinks: [
{ name: 'GitHub', url: 'https://github.com/yourusername', label: '...' },
// Add more...
]
};Edit src/data/projects.js:
export const projectsData = [
{
id: 4,
title: 'Your New Project',
tech: 'Tech Stack',
image: 'image-url',
alt: 'Descriptive alt text'
},
// ...
];Edit tailwind.config.js:
colors: {
accent: '#YOUR_BRAND_COLOR',
navy: '#YOUR_DARK_COLOR',
// ...
}| Technology | Purpose |
|---|---|
| React 18 | UI library with hooks |
| Vite | Lightning-fast build tool |
| Tailwind CSS | Utility-first CSS (tree-shakable) |
| React Helmet Async | SEO meta tags |
| Material Symbols | Icon library |
// ❌ Original (inline handler)
<button onclick="downloadSource()">Download</button>
// ✅ React (custom hook)
const handleDownload = useDownloadSource();
<button onClick={handleDownload}>Download</button>// ❌ Original (CDN)
<script src="https://cdn.tailwindcss.com"></script>
// ✅ React (npm + PostCSS)
// tailwind.config.js with tree-shaking// ❌ Original
<img src="..." alt="..." />
// ✅ React (with error handling)
<img
src="..."
alt="..."
loading="lazy"
onError={handleImageError}
/>// ❌ Original
<a href="#">GitHub</a>
// ✅ React
<a href="#" aria-label="Visit my GitHub profile">GitHub</a>npm install -g vercel
vercelnpm run build
# Drag 'dist' folder to NetlifyUpdate vite.config.js:
export default defineConfig({
base: '/your-repo-name/',
// ...
})- ✅ Single Responsibility: Each component does ONE thing
- ✅ No Direct DOM: Use
useRefor state, NEVERquerySelector - ✅ Functional Only: No class components
- ✅ Extract Logic: Complex logic goes in
src/hooks/ - ✅ Semantic HTML: Use
<article>,<section>,<nav>, etc.
- Components: PascalCase (
HeroSection.jsx) - Hooks: camelCase with
useprefix (useDownloadSource.js) - Data: camelCase (
projects.js) - Styles: kebab-case (
global.css)
This template was built following strict architectural standards. When contributing:
- Follow the Atomic Design structure (common → ui → sections)
- NO inline styles (use Tailwind or CSS modules)
- Add accessibility labels to all interactive elements
- Extract non-UI logic to custom hooks
- Use semantic HTML elements
MIT License - feel free to use for personal or commercial projects.
Built with ❤️ following Principal Frontend Architect standards
Original monolithic HTML → Modern React application with SOLID principles, Atomic Design, and production-ready architecture.