How kr1shnasomani/portfolio-website works
Project type and purpose
• This is a single-page portfolio website:
– Frontend-only (no custom backend code in this repo)
– Built with React (TSX), TypeScript, Vite, Tailwind CSS
– Static assets (images, CSS, JS) served from /public or via your hosting/CDN
• Main goal: showcase personal achievements, projects, certifications, skills
File structure
• Top-level:
– index.html: SPA entrypoint
– vite.config.ts, tsconfig.json, tailwind.config.ts: build & tooling configs
– package.json / bun.lockb / node_modules (implicit): dependencies
• src/: application code
– main.tsx → mounts <App>
– App.tsx + App.css → root component & global styles
– components/: domain widgets (AchievementCarousel, SkillsGrid, etc.)
– components/ui/: design‐system primitives (button.tsx, dialog.tsx, table.tsx, etc.)
– hooks/: cross‐cutting hooks (use-mobile, use-toast)
– lib/: shared utilities (utils.ts)
– pages/: route targets (Index.tsx, NotFound.tsx)
• public/: static hosting folder (robots.txt, uploads)
README
• Title only (“Portfolio Website”) → confirms it is a frontend showcase
• No mention of backend microservices or API layers
Main components & interactions
a. Developer Workstation
– Edits src/
– Runs Vite Dev Server → hot-reloads
– Runs npm run build → generates dist/ (index.html, CSS, JS bundles, copied /public assets)
b. CI/CD / Build Pipeline
– (Optional) GitHub Actions or similar picks up repo → npm ci → npm run build → outputs artifacts
– Deploys to static hosting (Netlify, Vercel, S3 + CloudFront, GitHub Pages)
c. Hosting / CDN
– Serves index.html, JS, CSS, images, /uploads
d. Client Browser
– Requests index.html
– Loads JS bundle → React hydrates in the DOM
– React Router (implicit via pages/Index.tsx & 404) determines views
– Components import from components/ and components/ui/
– UI events trigger local state / toast notifications (use-toast), no external API calls
e. Static asset interactions
– Images or uploads (under public/uploads) rendered in carousels
– CSS (App.css, Tailwind directives) applied at build time
Architectural patterns & design principles
• Single-Page App (SPA)
• Component-based architecture
• Design-System primitives (components/ui) vs. domain widgets (components/)
• Build pipeline separation: Dev Server vs. Production build
• Static hosting / CDN delivery