# delta6626/365-days-of-code architecture

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

- Interactive diagram: https://gitdiagram.com/delta6626/365-days-of-code
- Repository: https://github.com/delta6626/365-days-of-code

## Overview

##### Project type and purpose
- At the top level, this repository ("365 Days of Code") is a container for one mini-project per day.
- The only “full-stack” application in here is the Day 9 project “Nebula,” a note-taking SPA built with React/Vite and Firebase.

##### File structure
- Top-level folders “day1” through “day9-dayx” each contain independent front-end demos (HTML/CSS/JS) or simple apps.
– src/main.jsx & index.css: app bootstrap
– src/firebase: Firebase configuration + service functions
– src/features:
- core (page layout components)
- auth (login/signup)
- components (modals, editor, dashboard widgets)
– src/store: reactive state stores for notes, notebooks, theme, user, etc.
– src/utils: small helper functions
- vite.config.js and package.json define the build/dev toolchain.

##### Key insights from README
- The repo is largely a scratchpad—but Nebula is the showcase “system.”
- Nebula uses Firebase for authentication, data storage, and integrates a third-party quotes API.
- Nebula employs feature-based code organization and a centralized store (likely Zustand or a similar library).

## Diagram (Mermaid)

```mermaid
flowchart TB
    subgraph "Developer Workstation"
        DS["Developer Workstation"]:::client
        ViteConfig["vite.config.js"]:::client
        PackageJSON["package.json"]:::client
    end

    subgraph "Browser / React App"
        Main["src/main.jsx"]:::client
        IndexCSS["src/index.css"]:::client

        subgraph "Feature Modules"
            CoreFeatures["src/features/core"]:::client
            AuthFeatures["src/features/auth"]:::client
            UIComponents["src/features/components"]:::client
        end

        subgraph "State Management"
            StoresDir["src/store"]:::client
        end

        subgraph "Utilities & Helpers"
            UtilsDir["src/utils"]:::client
        end

        subgraph "Constants"
            ConstDir["src/constants"]:::client
        end

        subgraph "Assets (SVG/Icons)"
            AssetsDir["src/assets"]:::client
        end

        subgraph "Service Layer"
            FirebaseConfig["src/firebase/firebaseConfig.js"]:::client
            FirebaseServices["src/firebase/services.js"]:::client
        end

        IndexHTML["index.html"]:::client
    end

    subgraph "Backend Services"
        AuthService["Firebase Auth"]:::backend
        FirestoreDB["Firestore Database"]:::backend
        Hosting["Static Hosting"]:::backend
    end

    QuotesAPI["Quotable API"]:::external

    DS -->|"runs dev server"| ViteConfig
    DS -->|"runs dev server"| PackageJSON
    DS -->|"starts app"| Main

    Main -->|"bootstraps app"| CoreFeatures
    Main -->|"bootstraps app"| AuthFeatures
    Main -->|"bootstraps app"| UIComponents
    Main -->|"bootstraps app"| StoresDir
    Main -->|"bootstraps app"| UtilsDir
    Main -->|"bootstraps app"| ConstDir
    Main -->|"bootstraps app"| AssetsDir
    Main -->|"renders shell"| IndexHTML

    UIComponents -->|"dispatches actions"| StoresDir
    CoreFeatures -->|"uses components"| UIComponents
    AuthFeatures -->|"uses components"| UIComponents

    StoresDir -->|"calls services"| FirebaseServices
    UtilsDir -->|"utility calls"| FirebaseServices
    FirebaseConfig -->|"provides config"| FirebaseServices

    FirebaseServices -->|“authenticate”| AuthService
    FirebaseServices -->|“CRUD notes”| FirestoreDB
    FirebaseServices -->|“fetch quotes”| QuotesAPI
    QuotesAPI -->|“quote data”| FirebaseServices
    AuthService -->|“auth result”| FirebaseServices
    FirestoreDB -->|“data response”| FirebaseServices

    ViteConfig -->|"build output"| Hosting
    IndexHTML -->|"served from"| Hosting

    click ViteConfig "https://github.com/delta6626/365-days-of-code/blob/main/day9-dayx/nebula/vite.config.js"
    click PackageJSON "https://github.com/delta6626/365-days-of-code/blob/main/day9-dayx/nebula/package.json"
    click Main "https://github.com/delta6626/365-days-of-code/blob/main/day9-dayx/nebula/src/main.jsx"
    click IndexCSS "https://github.com/delta6626/365-days-of-code/blob/main/day9-dayx/nebula/src/index.css"
    click FirebaseConfig "https://github.com/delta6626/365-days-of-code/blob/main/day9-dayx/nebula/src/firebase/firebaseConfig.js"
    click FirebaseServices "https://github.com/delta6626/365-days-of-code/blob/main/day9-dayx/nebula/src/firebase/services.js"
    click CoreFeatures "https://github.com/delta6626/365-days-of-code/tree/main/day9-dayx/nebula/src/features/core"
    click AuthFeatures "https://github.com/delta6626/365-days-of-code/tree/main/day9-dayx/nebula/src/features/auth"
    click UIComponents "https://github.com/delta6626/365-days-of-code/tree/main/day9-dayx/nebula/src/features/components"
    click StoresDir "https://github.com/delta6626/365-days-of-code/tree/main/day9-dayx/nebula/src/store"
    click UtilsDir "https://github.com/delta6626/365-days-of-code/tree/main/day9-dayx/nebula/src/utils"
    click ConstDir "https://github.com/delta6626/365-days-of-code/tree/main/day9-dayx/nebula/src/constants"
    click AssetsDir "https://github.com/delta6626/365-days-of-code/tree/main/day9-dayx/nebula/src/assets"
    click IndexHTML "https://github.com/delta6626/365-days-of-code/blob/main/day9-dayx/nebula/index.html"

    classDef client fill:#ADD8E6,stroke:#333,stroke-width:1px
    classDef backend fill:#B8E986,stroke:#333,stroke-width:1px
    classDef external fill:#FFD27F,stroke:#333,stroke-width:1px
```
