# lexih209/bulletinboard architecture

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

- Interactive diagram: https://gitdiagram.com/lexih209/bulletinboard
- Repository: https://github.com/lexih209/bulletinboard

## Overview

BulletinBoard is a campus events board: students register or log in, browse and filter flyers, view details, and create, edit, or delete postings. The React routes call an Express API, which handles authentication/session checks and flyer operations against SQLite; flyer creation also supports image uploads. Documented admin controls and filtering are represented, but their unsampled details are not expanded. Relationships follow the shown frontend fetches, route declarations, and backend database usage; only excerpts and README claims were available.

Main entry points: [`backend/server.js`](https://github.com/lexih209/bulletinboard/blob/main/backend/server.js) (Express API), [`frontend/src/App.tsx`](https://github.com/lexih209/bulletinboard/blob/main/frontend/src/App.tsx) (Route application), [`frontend/src/pages/FlyerDetails.tsx`](https://github.com/lexih209/bulletinboard/blob/main/frontend/src/pages/FlyerDetails.tsx) (Flyer details), [`frontend/src/pages/BulletinBoard.tsx`](https://github.com/lexih209/bulletinboard/blob/main/frontend/src/pages/BulletinBoard.tsx) (Flyer board)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_frontend["Student experience"]
  node_app["Route application<br/>[App.tsx]"]
  node_welcome["Login<br/>[Welcome.tsx]"]
  node_register["Registration<br/>[Register.tsx]"]
  node_board["Flyer board<br/>[BulletinBoard.tsx]"]
  node_details["Flyer details<br/>[FlyerDetails.tsx]"]
  node_upload["Flyer upload<br/>[UploadFlyer.tsx]"]
  node_edit["Flyer editing<br/>[EditFlyer.tsx]"]
end

subgraph group_backend["API and access"]
  node_api["Express API<br/>[server.js]"]
  node_auth["Authentication<br/>[server.js]"]
  node_flyer_ops["Flyer operations<br/>[server.js]"]
  node_uploads["Image uploads<br/>[server.js]"]
end

subgraph group_persistence["Flyer data"]
  node_sqlite[("SQLite database<br/>[database.js]")]
end

node_student(("Student"))

node_student -->|"uses"| node_app
node_app -->|"routes to"| node_welcome
node_app -->|"routes to"| node_register
node_app -->|"routes to"| node_board
node_app -->|"routes to"| node_details
node_app -->|"routes to"| node_edit
node_app -->|"routes to"| node_upload
node_welcome -->|"posts login"| node_api
node_register -->|"posts registration"| node_api
node_board -->|"fetches flyers"| node_api
node_board -->|"links to"| node_details
node_board -->|"posts logout"| node_api
node_details -->|"fetches details"| node_api
node_details -->|"checks admin"| node_api
node_details -->|"deletes flyer"| node_api
node_details -->|"links to edit"| node_edit
node_upload -->|"submits flyer"| node_api
node_edit -->|"loads and updates"| node_api
node_api -->|"handles sessions"| node_auth
node_api -->|"dispatches routes"| node_flyer_ops
node_flyer_ops -->|"reads and writes"| node_sqlite
node_auth -->|"queries users"| node_sqlite
node_flyer_ops -->|"accepts image"| node_uploads

click node_app "https://github.com/lexih209/bulletinboard/blob/main/frontend/src/App.tsx"
click node_welcome "https://github.com/lexih209/bulletinboard/blob/main/frontend/src/pages/Welcome.tsx"
click node_register "https://github.com/lexih209/bulletinboard/blob/main/frontend/src/pages/Register.tsx"
click node_board "https://github.com/lexih209/bulletinboard/blob/main/frontend/src/pages/BulletinBoard.tsx"
click node_details "https://github.com/lexih209/bulletinboard/blob/main/frontend/src/pages/FlyerDetails.tsx"
click node_upload "https://github.com/lexih209/bulletinboard/blob/main/frontend/src/pages/UploadFlyer.tsx"
click node_edit "https://github.com/lexih209/bulletinboard/blob/main/frontend/src/pages/EditFlyer.tsx"
click node_api "https://github.com/lexih209/bulletinboard/blob/main/backend/server.js"
click node_auth "https://github.com/lexih209/bulletinboard/blob/main/backend/server.js"
click node_flyer_ops "https://github.com/lexih209/bulletinboard/blob/main/backend/server.js"
click node_uploads "https://github.com/lexih209/bulletinboard/blob/main/backend/server.js"
click node_sqlite "https://github.com/lexih209/bulletinboard/blob/main/backend/database.js"

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_app,node_welcome,node_register,node_board,node_details,node_upload,node_edit toneBlue
class node_api,node_auth,node_flyer_ops,node_uploads toneAmber
class node_sqlite toneMint
class node_student toneIndigo
```

## Components

### Student experience

- [Route application](https://github.com/lexih209/bulletinboard/blob/main/frontend/src/App.tsx): `frontend/src/App.tsx`
- [Login](https://github.com/lexih209/bulletinboard/blob/main/frontend/src/pages/Welcome.tsx): `frontend/src/pages/Welcome.tsx`
- [Registration](https://github.com/lexih209/bulletinboard/blob/main/frontend/src/pages/Register.tsx): `frontend/src/pages/Register.tsx`
- [Flyer board](https://github.com/lexih209/bulletinboard/blob/main/frontend/src/pages/BulletinBoard.tsx): `frontend/src/pages/BulletinBoard.tsx`
- [Flyer details](https://github.com/lexih209/bulletinboard/blob/main/frontend/src/pages/FlyerDetails.tsx): `frontend/src/pages/FlyerDetails.tsx`
- [Flyer upload](https://github.com/lexih209/bulletinboard/blob/main/frontend/src/pages/UploadFlyer.tsx): `frontend/src/pages/UploadFlyer.tsx`
- [Flyer editing](https://github.com/lexih209/bulletinboard/blob/main/frontend/src/pages/EditFlyer.tsx): `frontend/src/pages/EditFlyer.tsx`

### API and access

- [Express API](https://github.com/lexih209/bulletinboard/blob/main/backend/server.js): `backend/server.js`
- [Authentication](https://github.com/lexih209/bulletinboard/blob/main/backend/server.js): `backend/server.js`
- [Flyer operations](https://github.com/lexih209/bulletinboard/blob/main/backend/server.js): `backend/server.js`
- [Image uploads](https://github.com/lexih209/bulletinboard/blob/main/backend/server.js): `backend/server.js`

### Flyer data

- [SQLite database](https://github.com/lexih209/bulletinboard/blob/main/backend/database.js): `backend/database.js`

### Other components

- **Student**

## Connections

- Student → Route application: uses
- Route application → Login: routes to (evidence: `frontend/src/App.tsx`)
- Route application → Registration: routes to (evidence: `frontend/src/App.tsx`)
- Route application → Flyer board: routes to (evidence: `frontend/src/App.tsx`)
- Route application → Flyer details: routes to (evidence: `frontend/src/App.tsx`)
- Route application → Flyer editing: routes to (evidence: `frontend/src/App.tsx`)
- Route application → Flyer upload: routes to (evidence: `frontend/src/App.tsx`)
- Login → Express API: posts login (evidence: `frontend/src/pages/Welcome.tsx`)
- Registration → Express API: posts registration (evidence: `frontend/src/pages/Register.tsx`)
- Flyer board → Express API: fetches flyers (evidence: `frontend/src/pages/BulletinBoard.tsx`)
- Flyer board → Flyer details: links to (evidence: `frontend/src/pages/BulletinBoard.tsx`)
- Flyer board → Express API: posts logout (evidence: `frontend/src/pages/BulletinBoard.tsx`)
- Flyer details → Express API: fetches details (evidence: `frontend/src/pages/FlyerDetails.tsx`)
- Flyer details → Express API: checks admin (evidence: `frontend/src/pages/FlyerDetails.tsx`)
- Flyer details → Express API: deletes flyer (evidence: `frontend/src/pages/FlyerDetails.tsx`)
- Flyer details → Flyer editing: links to edit (evidence: `frontend/src/pages/FlyerDetails.tsx`)
- Flyer upload → Express API: submits flyer (evidence: `frontend/src/pages/UploadFlyer.tsx`)
- Flyer editing → Express API: loads and updates (evidence: `frontend/src/pages/EditFlyer.tsx`)
- Express API → Authentication: handles sessions (evidence: `backend/server.js`)
- Express API → Flyer operations: dispatches routes (evidence: `backend/server.js`)
- Flyer operations → SQLite database: reads and writes (evidence: `backend/server.js`)
- Authentication → SQLite database: queries users (evidence: `backend/server.js`)
- Flyer operations → Image uploads: accepts image (evidence: `backend/server.js`)
