# alekseyshgit/isimui architecture

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

- Interactive diagram: https://gitdiagram.com/alekseyshgit/isimui
- Repository: https://github.com/alekseyshgit/isimui

## Overview

##### Project type and purpose
- From the file tree and README, this is a full‐stack web application scaffolded with Vue 3 and Vite for the frontend, plus a Node.js “server.js” at the root that bundles and serves the SPA (and provides server‐side APIs or proxying).
- The presence of scripts like install-service.js, ecosystem.config.js, and offline/minimal packaging directories indicates this app is designed to be packaged (online or offline) and run as a service (PM2 or Windows Service).

##### File structure
- Top‐level “src/” holds the Vue 3 SPA:
- src/main.js, src/App.vue, src/components, src/views, src/router → client UI, routing, component tree.
- src/services & nested api/auth/util directories → client‐side service wrappers for REST or external ISIM APIs.
- “public/index.html” is the single‐page application entry point.
- “server.js” at root launches an HTTP server (likely Express) to serve static built assets and may expose custom server APIs.
- “minimal-package/” and “offline-package/” are pre‐built bundles plus scripts for installing as a local service.
- Config files: vite.config.js, ecosystem.config.js, package.json / package-lock.json.

##### Key insights from README
- Minimal default text: it’s a Vue 3 + Vite template, so the architecture is client‐heavy SPA.

##### Detailed callout of components
- Frontend:
- src/main.js (bootstraps app)
- src/router/index.js (client routing)
- src/views/*.vue (page views: LoginView, MainView)
- src/components/*.vue (UI widgets)
- src/services/* (client API wrappers)
- Backend:
- server.js (Express static + API)
- install-service.js / uninstall-service.js (service lifecycle)
- ecosystem.config.js (PM2 cluster config)
- Packaging:
- minimal-package/server.js + start.js
- offline-package/install-service.js + server.js + package.json

## Diagram (Mermaid)

```mermaid
graph TD
    subgraph "Frontend Layer"
        direction TB
        Browser["Browser / SPA"]:::frontend
        subgraph "Vue 3 SPA"
            direction TB
            Main["src/main.js"]:::frontend
            App["src/App.vue"]:::frontend
            Router["src/router/index.js"]:::frontend
            subgraph "Views"
                direction TB
                LoginView["LoginView.vue"]:::frontend
                MainView["MainView.vue"]:::frontend
            end
            subgraph "Components"
                direction TB
                HelloWorld["HelloWorld.vue"]:::frontend
                PersonRow["PersonRow.vue"]:::frontend
            end
            subgraph "Services"
                direction TB
                AuthService["AuthService.js"]:::frontend
                UserService["UserService.js"]:::frontend
                ISIMClient["ISIMClient.js"]:::frontend
            end
            subgraph "API Clients"
                direction TB
                PeopleClient["PeopleClient.js"]:::frontend
                AuthClient["AuthClient.js"]:::frontend
            end
            Utils["credentials.js"]:::frontend
            Config["config.js"]:::frontend
            Styles["style.css"]:::frontend
        end
    end

    subgraph "Backend Layer"
        direction TB
        NodeServer["server.js"]:::backend
        StaticServer["Static File Server"]:::backend
        APIEndpoints["API Endpoints"]:::backend
    end

    subgraph "External Services"
        direction TB
        ISIM["ISIM Identity Service"]:::external
    end

    subgraph "Deployment & Packaging"
        direction TB
        PM2["PM2 (ecosystem.config.js)"]:::deploy
        WinService["Windows Service<br/>install-service.js<br/>uninstall-service.js"]:::deploy
        subgraph "Packages"
            direction TB
            Minimal["minimal-package/server.js<br/>minimal-package/start.js"]:::deploy
            Offline["offline-package/server.js<br/>offline-package/install-service.js<br/>offline-package/uninstall-service.js"]:::deploy
        end
        PS["create-minimal-package.ps1<br/>create-offline-package.ps1"]:::deploy
    end

    %% Connections
    Browser -->|"loads SPA"| Main
    Browser -->|"navigates via router"| Router
    Browser -->|"calls API"| APIEndpoints
    Browser -->|"direct calls"| PeopleClient
    Browser -->|"direct calls"| AuthClient
    NodeServer -->|"serves static"| StaticServer
    NodeServer -->|"exposes REST"| APIEndpoints
    APIEndpoints -->|"proxy/auth"| ISIM
    PeopleClient -->|"calls"| ISIM
    AuthClient -->|"auth calls"| ISIM
    NodeServer -.-> PM2
    NodeServer -.-> WinService
    PM2 --> Minimal
    WinService --> Offline
    PS --> Minimal
    PS --> Offline

    %% Click Events
    click Main "https://github.com/alekseyshgit/isimui/blob/release/src/main.js"
    click App "https://github.com/alekseyshgit/isimui/blob/release/src/App.vue"
    click Router "https://github.com/alekseyshgit/isimui/blob/release/src/router/index.js"
    click LoginView "https://github.com/alekseyshgit/isimui/blob/release/src/views/LoginView.vue"
    click MainView "https://github.com/alekseyshgit/isimui/blob/release/src/views/MainView.vue"
    click HelloWorld "https://github.com/alekseyshgit/isimui/blob/release/src/components/HelloWorld.vue"
    click PersonRow "https://github.com/alekseyshgit/isimui/blob/release/src/components/PersonRow.vue"
    click AuthService "https://github.com/alekseyshgit/isimui/blob/release/src/services/AuthService.js"
    click UserService "https://github.com/alekseyshgit/isimui/blob/release/src/services/UserService.js"
    click ISIMClient "https://github.com/alekseyshgit/isimui/blob/release/src/services/ISIMClient.js"
    click PeopleClient "https://github.com/alekseyshgit/isimui/blob/release/src/services/api/PeopleClient.js"
    click AuthClient "https://github.com/alekseyshgit/isimui/blob/release/src/services/auth/AuthClient.js"
    click Utils "https://github.com/alekseyshgit/isimui/blob/release/src/services/utils/credentials.js"
    click Config "https://github.com/alekseyshgit/isimui/blob/release/src/config.js"
    click Styles "https://github.com/alekseyshgit/isimui/blob/release/src/style.css"
    click NodeServer "https://github.com/alekseyshgit/isimui/blob/release/server.js"
    click PM2 "https://github.com/alekseyshgit/isimui/blob/release/ecosystem.config.js"
    click WinService "https://github.com/alekseyshgit/isimui/blob/release/install-service.js"
    click WinService "https://github.com/alekseyshgit/isimui/blob/release/uninstall-service.js"
    click Minimal "https://github.com/alekseyshgit/isimui/blob/release/minimal-package/server.js"
    click Minimal "https://github.com/alekseyshgit/isimui/blob/release/minimal-package/start.js"
    click Offline "https://github.com/alekseyshgit/isimui/blob/release/offline-package/server.js"
    click Offline "https://github.com/alekseyshgit/isimui/blob/release/offline-package/install-service.js"
    click Offline "https://github.com/alekseyshgit/isimui/blob/release/offline-package/uninstall-service.js"
    click PS "https://github.com/alekseyshgit/isimui/blob/release/create-minimal-package.ps1"
    click PS "https://github.com/alekseyshgit/isimui/blob/release/create-offline-package.ps1"

    %% Styles
    classDef frontend fill:#B3D4FC,stroke:#333,stroke-width:1px
    classDef backend fill:#C4F8C5,stroke:#333,stroke-width:1px
    classDef external fill:#EDEDED,stroke:#333,stroke-width:1px,stroke-dasharray: 5 5
    classDef deploy fill:#FDEBD0,stroke:#333,stroke-width:1px,stroke-dasharray: 2 2
```
