# hellogithub-team/geese architecture

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

- Interactive diagram: https://gitdiagram.com/hellogithub-team/geese
- Repository: https://github.com/hellogithub-team/geese

## Overview

##### Project type and purpose
- This is a full-stack, server-rendered React application built with Next.js and styled with Tailwind CSS. It powers the “HelloGitHub” community portal (“Geese”), where users browse, search, comment on, bookmark, and rate beginner-friendly open-source projects.

##### File structure
- Top-level config: Dockerfile, server.js, ecosystem.config.js for PM2, GitHub Actions workflows, ESLint/Prettier, Yarn.
- “pages/”: Next.js routes driving both SSR and SSG.
- “components/”: Reusable UI widgets (buttons, dialogs, navbar, etc.).
- “services/”: A thin client-side service layer that wraps HTTP calls to the HelloGitHub backend API.
- “public/”: Static assets (images, fonts, favicon, JSON locales for i18n).
- “data/” & “docs/”: Markdown docs, help content, images.
- Configuration for i18n (next-i18next.config.js), sitemap, postcss, Tailwind, TypeScript.

##### Insights from the README
- The app is deployed at hellogithub.com, with features centered around open-source project discovery and community interaction.
- No internal database code—data comes from an existing HelloGitHub API.

## Diagram (Mermaid)

```mermaid
flowchart TB
    %% Presentation/UI Layer
    subgraph "Presentation/UI Layer"
        direction TB
        Pages["Next.js Pages"]:::frontend
        Components["UI Components"]:::frontend
    end

    %% Static Assets / CDN
    subgraph "Static Assets / CDN"
        direction TB
        StaticAssets["Static Assets"]:::external
    end

    %% Internationalization
    subgraph "Internationalization"
        direction TB
        I18nConfig["i18n Config"]:::frontend
        Locales["Locale JSON Files"]:::frontend
    end

    %% Rendering Engine / Server
    subgraph "Rendering Engine / Server"
        direction TB
        NextServer["Next.js Server"]:::server
    end

    %% Service Layer
    subgraph "Service Layer"
        direction TB
        Services["API Wrappers"]:::server
    end

    %% External Backend API
    HelloGitHubAPI["HelloGitHub API"]:::external

    %% CI/CD Pipeline
    subgraph "CI/CD Pipeline"
        direction TB
        GitHubActions["GitHub Actions"]:::ci
        DockerImage["Docker Image"]:::ci
        PM2["PM2 Process Manager"]:::ci
    end

    %% Browser
    Browser["Browser"]:::frontend

    %% Data Flows
    Browser -->|"HTTP GET / Page"| NextServer
    Browser -->|"Fetch Assets"| StaticAssets
    NextServer -->|"Serve Assets"| StaticAssets
    NextServer -->|"Uses i18n"| I18nConfig
    I18nConfig -->|"Loads Locales"| Locales
    NextServer -->|"Calls"| Services
    Services -->|"HTTP Request"| HelloGitHubAPI
    HelloGitHubAPI -->|"JSON Data"| Services
    Services -->|"Data"| NextServer
    NextServer -->|"Rendered HTML"| Browser

    %% Deployment Flow
    GitHubActions -->|"Build & Push"| DockerImage
    DockerImage -->|"Deploy"| PM2
    PM2 -->|"Run"| NextServer

    %% Click Events
    click Pages "https://github.com/hellogithub-team/geese/tree/main/src/pages/"
    click Components "https://github.com/hellogithub-team/geese/tree/main/src/components/"
    click StaticAssets "https://github.com/hellogithub-team/geese/tree/main/public/"
    click I18nConfig "https://github.com/hellogithub-team/geese/blob/main/next-i18next.config.js"
    click Locales "https://github.com/hellogithub-team/geese/tree/main/public/locales/"
    click NextServer "https://github.com/hellogithub-team/geese/blob/main/server.js"
    click NextServer "https://github.com/hellogithub-team/geese/blob/main/next.config.js"
    click NextServer "https://github.com/hellogithub-team/geese/blob/main/tailwind.config.js"
    click NextServer "https://github.com/hellogithub-team/geese/blob/main/postcss.config.js"
    click NextServer "https://github.com/hellogithub-team/geese/blob/main/next-sitemap.config.js"
    click Services "https://github.com/hellogithub-team/geese/tree/main/src/services/"
    click GitHubActions "https://github.com/hellogithub-team/geese/tree/main/.github/workflows/"
    click DockerImage "https://github.com/hellogithub-team/geese/tree/main/Dockerfile"
    click PM2 "https://github.com/hellogithub-team/geese/blob/main/ecosystem.config.js"

    %% Styles
    classDef frontend fill:#D0E8FF,stroke:#0366D6,stroke-width:2px
    classDef server fill:#DFFFD0,stroke:#22863A,stroke-width:2px
    classDef external fill:#F0F0F0,stroke:#6A737D,stroke-width:2px
    classDef ci fill:#FFE4B5,stroke:#D2691E,stroke-width:2px
```
