# gedam12/portfolio architecture

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

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

## Overview

##### Project type and purpose
- This is a simple, single‐page static website (no backend code, frameworks, or build scripts).
- Key files: index.html (entry point), stylesheet.css (styles), main.js (client‐side behavior), img/ (static images).

##### File structure
- Top‐level assets live alongside your HTML:
– index.html: main document
– main.js: all JavaScript logic (event handlers, DOM updates, any AJAX)
– stylesheet.css: all styling rules
– img/: contains images referenced by HTML or CSS

##### README
- It’s empty, so no additional architectural hints. We’ll focus on a generic static‐site deployment pattern.

##### Main components
a. Client (User’s browser)
– Renders index.html, applies stylesheet.css, executes main.js
– May request images from img/
b. Static Asset Server / Hosting Environment
– Serves HTML, CSS, JS, image files over HTTP(S)
– Could be GitHub Pages, Netlify, Amazon S3 + CloudFront, or any simple web server
c. (Optional) External Dependencies
– If main.js loads any 3rd‐party scripts or APIs at runtime, represent those as external services.

##### Relationships and interactions
- Browser → HTTP GET → Asset Server: requests index.html
- Browser parses HTML → issues HTTP GETs for stylesheet.css, main.js, and any images
- main.js runs in browser → manipulates DOM, may call external APIs over AJAX/Fetch

##### Architectural patterns & design principles
- Client‐side rendering: all logic runs in the browser.
- Static file hosting: no dynamic backend, no database.
- Separation of concerns: HTML for structure, CSS for presentation, JS for behavior.

##### Putting it all together
– index.html
– stylesheet.css
– main.js
– img/*
- Protocols (HTTP(S)), caching layers (CDN), or hosting provider.

##### Detail without overcomplicating
- Every moving part (HTML, CSS, JS, images, hosting, optional APIs).
- Keep it simple: static‐site architecture has only client, server, and optional third‐party services.

## Diagram (Mermaid)

```mermaid
graph TB
    %% Client-side Components
    subgraph "User's Browser"
        direction TB
        HTML["index.html"] 
        CSS["stylesheet.css"]
        JS["main.js"]
        Images["img/*"]
    end

    %% Hosting/Infrastructure
    StaticServer["Static Asset Server / CDN"]

    %% External Services
    ExternalAPI["External API Service"]

    %% Connections
    HTML -->|"HTTP GET"| StaticServer
    CSS -->|"HTTP GET"| StaticServer
    JS -->|"HTTP GET"| StaticServer
    Images -->|"HTTP GET"| StaticServer
    JS -->|"AJAX/Fetch"| ExternalAPI

    %% Click Events
    click HTML "https://github.com/gedam12/portfolio/blob/main/index.html"
    click CSS "https://github.com/gedam12/portfolio/blob/main/stylesheet.css"
    click JS "https://github.com/gedam12/portfolio/blob/main/main.js"
    click Images "https://github.com/gedam12/portfolio/tree/main/img/"

    %% Styles
    classDef client fill:#ADD8E6,stroke:#333,stroke-width:1px
    classDef server fill:#90EE90,stroke:#333,stroke-width:1px
    classDef external fill:#FFC0CB,stroke:#333,stroke-width:1px

    class HTML,CSS,JS,Images client
    class StaticServer server
    class ExternalAPI external
```
