# budugahariprasad/notesapp architecture

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

- Interactive diagram: https://gitdiagram.com/budugahariprasad/notesapp
- Repository: https://github.com/budugahariprasad/notesapp

## Overview

This repository implements a notes application: a React interface lets users register or log in, then create and manage personal notes through an Express API backed by MongoDB. Note management includes listing, editing, search, tag filtering, pinning, archiving, trash, and restore. The graph follows shown frontend composition and backend routing/model calls; the main App implementation, database connector, and some backend modules were not excerpted, so their internal links are limited to indexed references or documented behavior.

Main entry points: [`NotesAPP-API-backend-main/frontend/src/components/Dashboard.jsx`](https://github.com/budugahariprasad/notesapp/blob/main/NotesAPP-API-backend-main/frontend/src/components/Dashboard.jsx) (Notes dashboard), [`NotesAPP-API-backend-main/backend/routes/note.js`](https://github.com/budugahariprasad/notesapp/blob/main/NotesAPP-API-backend-main/backend/routes/note.js) (Note routes), [`NotesAPP-API-backend-main/backend/index.js`](https://github.com/budugahariprasad/notesapp/blob/main/NotesAPP-API-backend-main/backend/index.js) (Express server), [`NotesAPP-API-backend-main/frontend/src/App.jsx`](https://github.com/budugahariprasad/notesapp/blob/main/NotesAPP-API-backend-main/frontend/src/App.jsx) (App shell)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_frontend["Web interface"]
  node_app["App shell<br/>[App.jsx]"]
  node_authpage["Authentication UI<br/>[AuthPage.jsx]"]
  node_dashboard["Notes dashboard<br/>[Dashboard.jsx]"]
  node_creator["Note creator<br/>[NoteCreator.jsx]"]
  node_sidebar["Navigation and tags<br/>[Sidebar.jsx]"]
  node_card["Note card<br/>[NoteCard.jsx]"]
  node_modal["Edit modal<br/>[NoteModal.jsx]"]
end

subgraph group_api["API and access"]
  node_server["Express server<br/>[index.js]"]
  node_useroutes["Account routes<br/>[user.js]"]
  node_noteroutes["Note routes<br/>[note.js]"]
  node_auth["JWT authentication<br/>[auth.js]"]
end

subgraph group_domain["Account and notes"]
  node_userctrl["Account operations<br/>[user.js]"]
  node_notectrl["Note operations<br/>[note.js]"]
end

subgraph group_persistence["MongoDB models"]
  node_userschema[("User model<br/>[user.js]")]
  node_noteschema[("Note model<br/>[notes.js]")]
  node_mongo[("MongoDB connection<br/>[connect.js]")]
end

node_user(("User"))

node_user -.->|"uses"| node_app
node_app -.->|"renders"| node_authpage
node_app -.->|"renders"| node_dashboard
node_dashboard -->|"renders"| node_creator
node_dashboard -->|"renders"| node_sidebar
node_dashboard -->|"renders"| node_card
node_dashboard -->|"renders"| node_modal
node_creator -.->|"submits notes"| node_dashboard
node_dashboard -->|"requests notes API"| node_noteroutes
node_authpage -.->|"requests account API"| node_useroutes
node_server -->|"connects"| node_mongo
node_server -->|"mounts"| node_useroutes
node_server -->|"mounts"| node_noteroutes
node_useroutes -->|"routes to"| node_userctrl
node_noteroutes -->|"authenticates"| node_auth
node_noteroutes -->|"routes to"| node_notectrl
node_userctrl -->|"queries"| node_userschema
node_notectrl -->|"queries"| node_noteschema

click node_app "https://github.com/budugahariprasad/notesapp/blob/main/NotesAPP-API-backend-main/frontend/src/App.jsx"
click node_authpage "https://github.com/budugahariprasad/notesapp/blob/main/NotesAPP-API-backend-main/frontend/src/components/AuthPage.jsx"
click node_dashboard "https://github.com/budugahariprasad/notesapp/blob/main/NotesAPP-API-backend-main/frontend/src/components/Dashboard.jsx"
click node_creator "https://github.com/budugahariprasad/notesapp/blob/main/NotesAPP-API-backend-main/frontend/src/components/NoteCreator.jsx"
click node_sidebar "https://github.com/budugahariprasad/notesapp/blob/main/NotesAPP-API-backend-main/frontend/src/components/Sidebar.jsx"
click node_card "https://github.com/budugahariprasad/notesapp/blob/main/NotesAPP-API-backend-main/frontend/src/components/NoteCard.jsx"
click node_modal "https://github.com/budugahariprasad/notesapp/blob/main/NotesAPP-API-backend-main/frontend/src/components/NoteModal.jsx"
click node_server "https://github.com/budugahariprasad/notesapp/blob/main/NotesAPP-API-backend-main/backend/index.js"
click node_useroutes "https://github.com/budugahariprasad/notesapp/blob/main/NotesAPP-API-backend-main/backend/routes/user.js"
click node_noteroutes "https://github.com/budugahariprasad/notesapp/blob/main/NotesAPP-API-backend-main/backend/routes/note.js"
click node_auth "https://github.com/budugahariprasad/notesapp/blob/main/NotesAPP-API-backend-main/backend/middlewares/auth.js"
click node_userctrl "https://github.com/budugahariprasad/notesapp/blob/main/NotesAPP-API-backend-main/backend/controllers/user.js"
click node_notectrl "https://github.com/budugahariprasad/notesapp/blob/main/NotesAPP-API-backend-main/backend/controllers/note.js"
click node_userschema "https://github.com/budugahariprasad/notesapp/blob/main/NotesAPP-API-backend-main/backend/models/user.js"
click node_noteschema "https://github.com/budugahariprasad/notesapp/blob/main/NotesAPP-API-backend-main/backend/models/notes.js"
click node_mongo "https://github.com/budugahariprasad/notesapp/blob/main/NotesAPP-API-backend-main/backend/connect.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_authpage,node_dashboard,node_creator,node_sidebar,node_card,node_modal,node_user toneBlue
class node_server,node_useroutes,node_noteroutes,node_auth toneAmber
class node_userctrl,node_notectrl toneMint
class node_userschema,node_noteschema,node_mongo toneRose
```

## Components

### Web interface

- [App shell](https://github.com/budugahariprasad/notesapp/blob/main/NotesAPP-API-backend-main/frontend/src/App.jsx): `NotesAPP-API-backend-main/frontend/src/App.jsx`
- [Authentication UI](https://github.com/budugahariprasad/notesapp/blob/main/NotesAPP-API-backend-main/frontend/src/components/AuthPage.jsx): `NotesAPP-API-backend-main/frontend/src/components/AuthPage.jsx`
- [Notes dashboard](https://github.com/budugahariprasad/notesapp/blob/main/NotesAPP-API-backend-main/frontend/src/components/Dashboard.jsx): `NotesAPP-API-backend-main/frontend/src/components/Dashboard.jsx`
- [Note creator](https://github.com/budugahariprasad/notesapp/blob/main/NotesAPP-API-backend-main/frontend/src/components/NoteCreator.jsx): `NotesAPP-API-backend-main/frontend/src/components/NoteCreator.jsx`
- [Navigation and tags](https://github.com/budugahariprasad/notesapp/blob/main/NotesAPP-API-backend-main/frontend/src/components/Sidebar.jsx): `NotesAPP-API-backend-main/frontend/src/components/Sidebar.jsx`
- [Note card](https://github.com/budugahariprasad/notesapp/blob/main/NotesAPP-API-backend-main/frontend/src/components/NoteCard.jsx): `NotesAPP-API-backend-main/frontend/src/components/NoteCard.jsx`
- [Edit modal](https://github.com/budugahariprasad/notesapp/blob/main/NotesAPP-API-backend-main/frontend/src/components/NoteModal.jsx): `NotesAPP-API-backend-main/frontend/src/components/NoteModal.jsx`

### API and access

- [Express server](https://github.com/budugahariprasad/notesapp/blob/main/NotesAPP-API-backend-main/backend/index.js): `NotesAPP-API-backend-main/backend/index.js`
- [Account routes](https://github.com/budugahariprasad/notesapp/blob/main/NotesAPP-API-backend-main/backend/routes/user.js): `NotesAPP-API-backend-main/backend/routes/user.js`
- [Note routes](https://github.com/budugahariprasad/notesapp/blob/main/NotesAPP-API-backend-main/backend/routes/note.js): `NotesAPP-API-backend-main/backend/routes/note.js`
- [JWT authentication](https://github.com/budugahariprasad/notesapp/blob/main/NotesAPP-API-backend-main/backend/middlewares/auth.js): `NotesAPP-API-backend-main/backend/middlewares/auth.js`

### Account and notes

- [Account operations](https://github.com/budugahariprasad/notesapp/blob/main/NotesAPP-API-backend-main/backend/controllers/user.js): `NotesAPP-API-backend-main/backend/controllers/user.js`
- [Note operations](https://github.com/budugahariprasad/notesapp/blob/main/NotesAPP-API-backend-main/backend/controllers/note.js): `NotesAPP-API-backend-main/backend/controllers/note.js`

### MongoDB models

- [User model](https://github.com/budugahariprasad/notesapp/blob/main/NotesAPP-API-backend-main/backend/models/user.js): `NotesAPP-API-backend-main/backend/models/user.js`
- [Note model](https://github.com/budugahariprasad/notesapp/blob/main/NotesAPP-API-backend-main/backend/models/notes.js): `NotesAPP-API-backend-main/backend/models/notes.js`
- [MongoDB connection](https://github.com/budugahariprasad/notesapp/blob/main/NotesAPP-API-backend-main/backend/connect.js): `NotesAPP-API-backend-main/backend/connect.js`

### Other components

- **User**

## Connections

- User → App shell: uses
- App shell → Authentication UI: renders
- App shell → Notes dashboard: renders
- Notes dashboard → Note creator: renders (evidence: `NotesAPP-API-backend-main/frontend/src/components/Dashboard.jsx`)
- Notes dashboard → Navigation and tags: renders (evidence: `NotesAPP-API-backend-main/frontend/src/components/Dashboard.jsx`)
- Notes dashboard → Note card: renders (evidence: `NotesAPP-API-backend-main/frontend/src/components/Dashboard.jsx`)
- Notes dashboard → Edit modal: renders (evidence: `NotesAPP-API-backend-main/frontend/src/components/Dashboard.jsx`)
- Note creator → Notes dashboard: submits notes (evidence: `NotesAPP-API-backend-main/frontend/src/components/Dashboard.jsx`)
- Notes dashboard → Note routes: requests notes API (evidence: `NotesAPP-API-backend-main/frontend/src/components/Dashboard.jsx`)
- Authentication UI → Account routes: requests account API
- Express server → MongoDB connection: connects (evidence: `NotesAPP-API-backend-main/backend/index.js`)
- Express server → Account routes: mounts (evidence: `NotesAPP-API-backend-main/backend/index.js`)
- Express server → Note routes: mounts (evidence: `NotesAPP-API-backend-main/backend/index.js`)
- Account routes → Account operations: routes to (evidence: `NotesAPP-API-backend-main/backend/routes/user.js`)
- Note routes → JWT authentication: authenticates (evidence: `NotesAPP-API-backend-main/backend/routes/note.js`)
- Note routes → Note operations: routes to (evidence: `NotesAPP-API-backend-main/backend/routes/note.js`)
- Account operations → User model: queries (evidence: `NotesAPP-API-backend-main/backend/controllers/user.js`)
- Note operations → Note model: queries (evidence: `NotesAPP-API-backend-main/backend/controllers/note.js`)
