# gotno/gtnoblg architecture

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

- Interactive diagram: https://gitdiagram.com/gotno/gtnoblg
- Repository: https://github.com/gotno/gtnoblg

## Overview

##### Main Components
- Content Repository – Represented by the src directory which holds:
- Blog posts: Files under src/vcvrvr (each file named with a date, e.g., “2023-03-01.liquid”). This folder essentially forms the content (blog posts) that the site renders.
- Templates and Layouts: Under src/_includes (layout.liquid, templates, style, etc.), these files define the structure of the pages and apply the visual styles.
- Assets: Images and possibly other static files (stored in src/assets and src/img).
- Build Engine – The Eleventy configuration (eleventy.config.js) and associated package.json scripts. This is the engine that takes the source content and templates and transforms them into a static site.
- Data/Configuration Files – Files such as vcvrvr.11tydata.js (which likely provides metadata or dynamic data for the blog posts) along with configuration files in the root (.gitignore, .tool-versions, package-lock.json, etc.) which support environment and dependency management.
- Deployment/Output Component – Even though not directly visible in the file tree, the output of the build process (the static site files) is destined for the blog domain (blog.gotno.net).

##### Relationships and Interactions
- The “src” directory is the heart of the project where content (blog posts), presentation (layouts and style files), and additional data (vcvrvr.11tydata.js) reside.
- The Eleventy build engine (configured via eleventy.config.js) reads the source content and applies the templates and styles to generate the final static output.
- Assets (images, CSS, additional resources) are integrated within the templates during the build process.
- The npm/package configuration files support dependency management and might trigger build commands, thereby linking development to production.

##### Architectural Patterns/Design Principles
- Separation of Concerns: Notice how content (blog posts), presentation (templates and styles), and configuration are segmented into different directories.
- Static Site Generation: The system is designed for static site generation using Eleventy, where runtime dependencies and databases are absent – the site is built at compile time.
- Use of Templating: Liquid templating is used to facilitate reusability and maintain consistency across the blog pages.

##### Relevant Technologies and Frameworks
- Eleventy (11ty) as the static site generator.
- Liquid Templating Language for the layout and content files.
- JavaScript (for the build process and possible dynamic data handling via files like vcvrvr.11tydata.js).
- npm for package management, and possibly Node.js as the underlying runtime.
- CSS approaches are evident via the style files (modular CSS files like _reset.css, _theme.css, etc.) ensuring styling is centralized.

## Diagram (Mermaid)

```mermaid
flowchart TD
    %% Source Repository Subgraphs
    subgraph "Source Repository"
        direction TB
        subgraph "Content"
            BlogPosts["Blog Posts (src/vcvrvr)"]:::source
            Metadata["vcvrvr Metadata (src/vcvrvr/vcvrvr.11tydata.js)"]:::source
        end
        subgraph "Presentation"
            Templates["Templates & Layouts (src/_includes)"]:::source
            PostTemplate["Post Template (src/_includes/templates/_post_alone.liquid)"]:::source
            Styles["Styles (src/_includes/style)"]:::source
        end
        subgraph "Assets"
            Assets["Assets (src/assets)"]:::source
            Images["Images (src/img/vcvrvr)"]:::source
        end
        Config["Environment Config (.gitignore, .tool-versions)"]:::source
    end

    %% Build & Configuration Subgraph
    subgraph "Build & Configuration"
        direction TB
        Engine["Build Engine (Eleventy)"]:::build
        Package["Package Config (package.json)"]:::build
    end

    %% Deployed Static Site
    DeploySite["Deployed Static Site (blog.gotno.net)"]:::deploy

    %% Relationships from Source to Build Engine
    BlogPosts -->|"feeds"| Engine
    Metadata -->|"provides data"| Engine
    Templates -->|"structures pages"| Engine
    PostTemplate -->|"used in"| Templates
    Styles -->|"styles pages"| Engine
    Assets -->|"serves static files"| Engine
    Images -->|"provides images"| Assets
    Config -->|"influences"| Engine
    Package -->|"configures"| Engine

    %% Relationship from Build Engine to Deployment
    Engine -->|"generates"| DeploySite

    %% Click Events
    click BlogPosts "https://github.com/gotno/gtnoblg/tree/main/src/vcvrvr"
    click Metadata "https://github.com/gotno/gtnoblg/blob/main/src/vcvrvr/vcvrvr.11tydata.js"
    click Templates "https://github.com/gotno/gtnoblg/tree/main/src/_includes"
    click PostTemplate "https://github.com/gotno/gtnoblg/blob/main/src/_includes/templates/_post_alone.liquid"
    click Styles "https://github.com/gotno/gtnoblg/tree/main/src/_includes/style"
    click Assets "https://github.com/gotno/gtnoblg/tree/main/src/assets"
    click Images "https://github.com/gotno/gtnoblg/tree/main/src/img/vcvrvr"
    click Engine "https://github.com/gotno/gtnoblg/blob/main/eleventy.config.js"
    click Package "https://github.com/gotno/gtnoblg/blob/main/package.json"

    %% Styles
    classDef source fill:#bbdefb,stroke:#0d47a1,stroke-width:2px;
    classDef build fill:#c5e1a5,stroke:#33691e,stroke-width:2px;
    classDef deploy fill:#ffe082,stroke:#ff6f00,stroke-width:2px;
```
