# joseph-bond-github/bridgnorthrc-booking architecture

> Architecture diagram of the GitHub repository joseph-bond-github/bridgnorthrc-booking, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-18). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/joseph-bond-github/bridgnorthrc-booking
- Repository: https://github.com/joseph-bond-github/bridgnorthrc-booking

## Overview

The repository describes a rowing-club booking website for boats and rowing machines, but the sampled runtime currently implements only a database-health display. The graph follows that implemented flow; booking capabilities are documented goals, not demonstrated subsystems. Source excerpts show the frontend request and API query, but do not establish a booking workflow.

Main entry points: [`server/src/server.ts`](https://github.com/joseph-bond-github/bridgnorthrc-booking/blob/main/server/src/server.ts) (Express API), [`web/src/App.tsx`](https://github.com/joseph-bond-github/bridgnorthrc-booking/blob/main/web/src/App.tsx) (Health display), [`web/src/main.tsx`](https://github.com/joseph-bond-github/bridgnorthrc-booking/blob/main/web/src/main.tsx) (React entry), [`server/src/db.ts`](https://github.com/joseph-bond-github/bridgnorthrc-booking/blob/main/server/src/db.ts) (Postgres pool)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_frontend["Frontend"]
  node_entry["React entry<br/>[main.tsx]"]
  node_app["Health display<br/>[App.tsx]"]
end

subgraph group_backend["Backend"]
  node_api["Express API<br/>[server.ts]"]
end

subgraph group_data["Data access"]
  node_pool["Postgres pool<br/>[db.ts]"]
end

node_user(("Club user"))
node_database[("PostgreSQL")]

node_user -->|"views"| node_entry
node_entry -->|"renders"| node_app
node_app -->|"fetches health"| node_api
node_api -->|"queries"| node_pool
node_pool -.->|"connects"| node_database
node_api -->|"returns time"| node_app

click node_entry "https://github.com/joseph-bond-github/bridgnorthrc-booking/blob/main/web/src/main.tsx"
click node_app "https://github.com/joseph-bond-github/bridgnorthrc-booking/blob/main/web/src/App.tsx"
click node_api "https://github.com/joseph-bond-github/bridgnorthrc-booking/blob/main/server/src/server.ts"
click node_pool "https://github.com/joseph-bond-github/bridgnorthrc-booking/blob/main/server/src/db.ts"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_entry,node_app,node_user toneBlue
class node_api,node_database toneAmber
class node_pool toneMint
```

## Components

### Frontend

- [React entry](https://github.com/joseph-bond-github/bridgnorthrc-booking/blob/main/web/src/main.tsx): `web/src/main.tsx`
- [Health display](https://github.com/joseph-bond-github/bridgnorthrc-booking/blob/main/web/src/App.tsx): `web/src/App.tsx`

### Backend

- [Express API](https://github.com/joseph-bond-github/bridgnorthrc-booking/blob/main/server/src/server.ts): `server/src/server.ts`

### Data access

- [Postgres pool](https://github.com/joseph-bond-github/bridgnorthrc-booking/blob/main/server/src/db.ts): `server/src/db.ts`

### Other components

- **Club user**
- **PostgreSQL**

## Connections

- Club user → React entry: views
- React entry → Health display: renders (evidence: `web/src/main.tsx`)
- Health display → Express API: fetches health (evidence: `web/src/App.tsx`)
- Express API → Postgres pool: queries (evidence: `server/src/server.ts`)
- Postgres pool → PostgreSQL: connects
- Express API → Health display: returns time (evidence: `web/src/App.tsx`)
