# shreya8660/portfolio architecture

> Architecture diagram of the GitHub repository shreya8660/portfolio, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-02-22). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/shreya8660/portfolio
- Repository: https://github.com/shreya8660/portfolio

## Overview

##### Project type & purpose (from README + tree)
This is a **static portfolio website** (no backend code present) hosted on **Vercel**. The purpose is to serve a personal portfolio page with styling, client-side interactivity, and downloadable/viewable documents (CV, certificates), plus images.

Key evidence:
- `Portfolio/index.html` → single-page/static entrypoint
- `Portfolio/styles.css` → styling
- `Portfolio/script.js` → client-side behavior only
- `Portfolio/assets/*.pdf`, `Portfolio/certificates/*.pdf`, `Portfolio/pic/*` → static media
- README links a Vercel deployment → typical static hosting + CDN delivery

##### Core runtime artifacts
- **HTML document**: `Portfolio/index.html`
- **CSS**: `Portfolio/styles.css`
- **JavaScript**: `Portfolio/script.js`

##### Static assets
- **CV PDF**: `Portfolio/assets/Shreya_V_CV.pdf`
- **Certificates PDFs**: `Portfolio/certificates/*`
- **Images**: `Portfolio/pic/*` (directory exists; contents not listed)

##### Supporting/metadata
- `README.md` (documentation)
- `.vscode/` (editor config; not runtime)

Because it’s static:
- **Client → Hosting (Vercel) → Static assets** is the main runtime flow.
- Any “logic” is **in-browser** (JS manipulating DOM, handling clicks, navigation, downloads).
- No DB, no server API is visible from the repo; avoid inventing one. If the site links to external services (e.g., LinkedIn, GitHub, email), show them as optional external nodes.

##### User / Browser (Client Runtime)
- Loads HTML/CSS/JS
- Executes `script.js`
- Renders DOM
- Fetches images/PDFs

##### Vercel Hosting (Static Site)
- Serves `index.html`, `styles.css`, `script.js`
- Serves static assets under `/assets`, `/certificates`, `/pic`

##### Vercel Edge Network / CDN
- This is key for accuracy on Vercel: requests are served from edge caches globally.

##### Source Repository (GitHub or similar)
- Not shown in tree, but typically Vercel deploys from Git.

##### External Links (Optional)

**Runtime request flow (critical):**
- Browser → CDN/Vercel: `GET /` (serves `index.html`)
- Browser → CDN/Vercel: `GET /styles.css`
- Browser → CDN/Vercel: `GET /script.js`
- Browser → CDN/Vercel: `GET /pic/...` (images)
- Browser → CDN/Vercel: `GET /assets/Shreya_V_CV.pdf`
- Browser → CDN/Vercel: `GET /certificates/...pdf`

**Client-side behavior flow (inside browser):**
- `script.js` → DOM (manipulate elements, handle navigation/scrolling/buttons)
- User interaction → `script.js` handlers → (may trigger) navigation/download requests for PDFs/images

- Engineer pushes to Git repo → Vercel deploy pipeline → CDN updated → users get new content

##### Architectural patterns used
For this project, call out:
- **Static site architecture** (no server-side app)
- **Client-side enhancement** (JS enhances UX; not required for serving content)
- **CDN-based delivery** (Vercel edge caching for performance)

Avoid patterns that aren’t evidenced (microservices, REST APIs, DB, queues).

##### Relevant tech labels
- “HTML/CSS/Vanilla JS”
- “Vercel Static Hosting + CDN”
- “PDF/Image static assets”

##### Clear labels for each component
Use exact names tied to repo:
- `index.html` (entrypoint)
- `styles.css` (styling)
- `script.js` (client-side logic)
- `/assets/*.pdf` (CV)
- `/certificates/*.pdf` (certificates)
- `/pic/*` (images)
- “Vercel Hosting / CDN”

##### “Separate into as many components as possible” (without inventing)
To be very detailed for this repo, break out these nodes explicitly:
- `index.html` (root document)
- `styles.css`
- `script.js`
- CV PDF (`assets/Shreya_V_CV.pdf`)
- Certificates PDFs (`certificates/Udemy.pdf`, `certificates/Yuvamytr.pdf`)
- Image directory (`pic/`)
- Hosting platform (Vercel)
- Edge CDN (Vercel)
- Browser cache (client-side)
- Optional external links (only if present in HTML)

That level of granularity is appropriate here because the system is small; accuracy comes from showing the **real runtime relationships** (browser requests static files; JS drives UI; PDFs/images are fetched as separate resources).

##### Quick checklist before finalizing
- Confirm paths and references by scanning `index.html` for:
- `<link href="styles.css">`
- `<script src="script.js">`
- `<img src="pic/...">`
- ``
- Any external CDNs (Google Fonts, Font Awesome). If present, add “External CDN” nodes.

This is the main “hidden architecture” static sites often have.

## Diagram (Mermaid)

```mermaid
flowchart TD
    %% =========================
    %% Runtime / Request Flow
    %% =========================
    U["User"]:::external

    subgraph "Client Runtime (Browser)"
        B["Browser"]:::compute
        Cache["Browser Cache"]:::compute
        subgraph "Rendering & Interactivity"
            DOM["DOM Renderer"]:::compute
            JSRT["JS Runtime"]:::compute
            UX["User Interactions<br/>(click/scroll/nav)"]:::compute
        end
    end

    subgraph "Vercel Platform"
        CDN["Vercel Edge Network (CDN)"]:::platform
        Host["Vercel Static Hosting (Origin)"]:::platform

        subgraph "Static Site Artifacts"
            HTML["index.html (Entrypoint)"]:::static
            CSS["styles.css (Styling)"]:::static
            JS["script.js (Client Logic)"]:::static

            subgraph "Static Media"
                CVPDF["Shreya_V_CV.pdf (CV)"]:::static
                CERTDIR["/certificates/ (PDFs)"]:::static
                UDEMY["Udemy.pdf"]:::static
                YUV["Yuvamytr.pdf"]:::static
                PICDIR["/pic/ (Images)"]:::static
            end
        end
    end

    %% Main navigation
    U -->|"uses"| B

    %% Requests (prefer edge; origin as fallback)
    B -->|"HTTP_GET /"| CDN
    CDN -->|"cache_miss/fetch"| Host
    Host -->|"serve"| HTML
    CDN -->|"deliver"| HTML
    HTML -->|"render"| DOM

    %% CSS
    B -->|"HTTP_GET /styles.css"| CDN
    CDN -->|"cache_miss/fetch"| Host
    Host -->|"serve"| CSS
    CDN -->|"deliver"| CSS
    CSS -->|"apply_styles"| DOM

    %% JS
    B -->|"HTTP_GET /script.js"| CDN
    CDN -->|"cache_miss/fetch"| Host
    Host -->|"serve"| JS
    CDN -->|"deliver"| JS
    JS -->|"execute_in"| JSRT
    JSRT -->|"manipulate"| DOM

    %% Client caching
    CDN -->|"cache_headers"| Cache
    Cache -->|"cache_hit"| B

    %% Interaction-driven fetches
    U -->|"click/scroll"| UX
    UX -->|"event_handlers"| JSRT

    JSRT -->|"navigate/download"| B
    B -->|"HTTP_GET /assets/Shreya_V_CV.pdf"| CDN
    CDN -->|"deliver"| CVPDF

    B -->|"HTTP_GET /certificates/*"| CDN
    CDN -->|"deliver"| CERTDIR
    CERTDIR -->|"includes"| UDEMY
    CERTDIR -->|"includes"| YUV

    B -->|"HTTP_GET /pic/*"| CDN
    CDN -->|"deliver"| PICDIR

    %% =========================
    %% Deployment / Delivery Pipeline
    %% =========================
    subgraph "Delivery Pipeline (Static)"
        DEV["Developer Workstation"]:::external
        REPO["Source Repository"]:::external
        DEPLOY["Vercel Deploy Pipeline<br/>(Deploy Static Assets)"]:::platform
    end

    DEV -->|"git_push"| REPO
    REPO -->|"trigger_deploy"| DEPLOY
    DEPLOY -->|"publish"| Host
    DEPLOY -->|"invalidate/update_cache"| CDN

    %% =========================
    %% Supporting / Metadata (Non-runtime)
    %% =========================
    subgraph "Project Metadata (Non-runtime)"
        README["README.md (Docs)"]:::meta
        VSCODE[".vscode/ (Editor Config)"]:::meta
    end

    README -.->|"documents"| REPO
    VSCODE -.->|"local_dev_only"| DEV

    %% Click Events (from component mapping)
    click HTML "https://github.com/shreya8660/portfolio/blob/main/Portfolio/index.html"
    click CSS "https://github.com/shreya8660/portfolio/blob/main/Portfolio/styles.css"
    click JS "https://github.com/shreya8660/portfolio/blob/main/Portfolio/script.js"
    click CVPDF "https://github.com/shreya8660/portfolio/blob/main/Portfolio/assets/Shreya_V_CV.pdf"
    click CERTDIR "https://github.com/shreya8660/portfolio/tree/main/Portfolio/certificates/"
    click UDEMY "https://github.com/shreya8660/portfolio/blob/main/Portfolio/certificates/Udemy.pdf"
    click YUV "https://github.com/shreya8660/portfolio/blob/main/Portfolio/certificates/Yuvamytr.pdf"
    click PICDIR "https://github.com/shreya8660/portfolio/tree/main/Portfolio/pic/"
    click README "https://github.com/shreya8660/portfolio/blob/main/README.md"
    click VSCODE "https://github.com/shreya8660/portfolio/tree/main/.vscode/"

    %% Styles
    classDef platform fill:#6f42c1,stroke:#3b1f6b,stroke-width:1.5px,color:#ffffff
    classDef compute fill:#1f77b4,stroke:#12486f,stroke-width:1.5px,color:#ffffff
    classDef static fill:#2ca02c,stroke:#1f6e1f,stroke-width:1.5px,color:#ffffff
    classDef external fill:#6c757d,stroke:#3d4246,stroke-width:1.5px,color:#ffffff
    classDef meta fill:#9aa0a6,stroke:#5f6368,stroke-width:1.2px,color:#111111
```
