# stvncode/portfolio_v2 architecture

> Architecture diagram of the GitHub repository stvncode/portfolio_v2, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2025-05-13). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/stvncode/portfolio_v2
- Repository: https://github.com/stvncode/portfolio_v2

## Overview

##### Project type and purpose
- This is a static/full-stack hybrid portfolio website built with Next.js (v14), React, TypeScript, and Tailwind CSS.
- Purpose: serve personal résumé data and a blog as a fast, responsive, SEO-friendly site. Content lives in markdown/MDX and TSX data files, compiled by Next.js into static and server-rendered pages.

##### File structure
- Top-level:
- next.config.mjs, tsconfig.json, tailwind.config.ts, postcss.config.mjs → build & configuration
- package.json, lockfiles → dependencies & scripts
- public/ → static assets (images, logos, favicon)
- src/app/ → Next.js App Router pages, layouts, global CSS
- src/components/ → reusable UI components (hackathon-card, magicui, Shadcn/ui primitives)
- src/data/ → data sources (resume.tsx, blog.ts)
- src/lib/ → utility functions
- content/ → blog posts in MDX
- Patterns:
- File-based routing (App Router)
- Component-based UI with CSS-in-JS (Tailwind) & animation libs (Framer Motion, Magic UI)
- MDX integration for blog content
- SSG/ISR and SSR falls back to static deployment

##### README for insights
- Confirms tech stack: Next.js, TypeScript, Shadcn/UI, TailwindCSS, Framer Motion, Magic UI.
- Mentions blog, responsive design, Vercel/Netlify/GitHub Pages deployment.
- Single config file (resume.tsx) for content changes.

## Diagram (Mermaid)

```mermaid
flowchart TD
    %% Entities
    Dev["Developer"]:::external
    GitHub["GitHub Repository"]:::external
    CI["CI/CD Pipeline"]:::build
    NextBuild["Next.js Build"]:::build
    CDN["CDN/Hosting (Vercel/Netlify)"]:::external
    Browser["Client Browser"]:::client

    %% Data Sources
    subgraph "Data Sources"
        DataResume["Resume Content"]:::data
        DataBlog["Blog Metadata"]:::data
        MDXFiles["MDX Content Files"]:::data
    end

    %% Next.js Build Internals
    subgraph "Next.js Build"
        AR["App Router"]:::code
        Routing["Routing & Layouts"]:::code
        Components["Component Layer"]:::code
        CSS["CSS Generation"]:::build
        MDXProc["MDX Processing"]:::build
    end

    %% Connections
    Dev -->|"push code"| GitHub
    GitHub -->|"trigger build"| CI
    CI -->|"run build"| NextBuild
    DataResume --> NextBuild
    DataBlog --> NextBuild
    MDXFiles --> NextBuild
    NextBuild -->|"deploy artifacts"| CDN
    CDN -->|"serve assets"| Browser
    Browser -->|"fetch assets"| CDN

    %% Build internals flow
    NextBuild --> AR
    AR --> Routing
    Routing --> Components
    Components --> MDXProc
    Components --> CSS

    %% Click Events
    click AR "https://github.com/stvncode/portfolio_v2/tree/main/src/app/"
    click Routing "https://github.com/stvncode/portfolio_v2/blob/main/src/app/layout.tsx"
    click Components "https://github.com/stvncode/portfolio_v2/tree/main/src/components/"
    click CSS "https://github.com/stvncode/portfolio_v2/blob/main/src/app/globals.css"
    click MDXProc "https://github.com/stvncode/portfolio_v2/blob/main/src/components/mdx.tsx"
    click DataResume "https://github.com/stvncode/portfolio_v2/blob/main/src/data/resume.tsx"
    click DataBlog "https://github.com/stvncode/portfolio_v2/blob/main/src/data/blog.ts"
    click MDXFiles "https://github.com/stvncode/portfolio_v2/tree/main/content/"
    click CI "https://github.com/stvncode/portfolio_v2/blob/main/package.json"
    click Dev "https://github.com/stvncode/portfolio_v2/blob/main/package.json"
    click Browser "https://github.com/stvncode/portfolio_v2/tree/main/public/"
    click GitHub "https://github.com/stvncode/portfolio_v2/blob/main/next.config.mjs"

    %% Class Definitions
    classDef code fill:#D0E8FF,stroke:#333,stroke-width:1px
    classDef build fill:#D0F0C0,stroke:#333,stroke-width:1px
    classDef data fill:#FFE0B2,stroke:#333,stroke-width:1px
    classDef external fill:#E1BEE7,stroke:#333,stroke-width:1px
    classDef client fill:#E1F5FE,stroke:#333,stroke-width:1px
```
