# andycodev/movies-frontend architecture

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

- Interactive diagram: https://gitdiagram.com/andycodev/movies-frontend
- Repository: https://github.com/andycodev/movies-frontend

## Overview

##### Project type and purpose
- This is a front-end Single-Page Application (SPA) scaffold built on Vue 3 and Vuetify 3.
- It includes no in-repo backend; all data comes from external REST APIs via a thin API layer.
- Key features: TypeScript, Vite bundler, Vue Router, Vuetify UI library, Pinia state management, automatic component imports.

##### File structure
- src/
- main.ts – app entry point
- App.vue – root component
- router/index.ts – Vue Router definitions
- plugins/ – Vuetify, other plugin initializers
- layouts/ – top-level layout components (AdminLayout, MoviesLayout)
- pages/ – feature pages (movies-admin, movies-list) under each layout
- components/ – reusable Vue components
- api/baseApi.ts – axios or fetch wrapper
- services/ – domain services calling baseApi (e.g. movies.service.ts)
- interfaces/ – TypeScript interfaces for API models
- assets/ & public/ – static assets
- Config & tool files: vite.config.mts, tsconfig*.json, package.json, .env, .gitignore

##### README
- Confirms stack (Vue 3, Vuetify 3, Vite, TypeScript, Pinia, Vue Router) and purpose (UI scaffolding).

## Diagram (Mermaid)

```mermaid
flowchart TB
    %% Browser / SPA Container
    subgraph "Browser / SPA" 
        direction TB
        MainTs["src/main.ts"]:::entry
        AppVue["src/App.vue"]:::entry
        Router["Vue Router\n(src/router/index.ts)"]:::routing
        PluginsIndex["Plugins\n(src/plugins/index.ts)"]:::plugin
        VuetifyPlugin["Vuetify Plugin\n(src/plugins/vuetify.ts)"]:::plugin
        AdminLayout["AdminLayout.vue"]:::ui
        MoviesLayout["MoviesLayout.vue"]:::ui
        subgraph "Pages and Composables"
            direction TB
            MoviesAdminPage["MoviesAdminPage.vue"]:::ui
            UseMoviesAdminPage["useMoviesAdminPage.ts"]:::logic
            MoviesListPage["MoviesListPage.vue"]:::ui
            UseMoviesListPage["useMoviesListPage.ts"]:::logic
        end
        HelloWorld["HelloWorld.vue"]:::ui
        Pinia["Pinia Store"]:::state
    end

    %% Data Access Layer
    subgraph "API Layer and Services"
        direction TB
        BaseApi["baseApi.ts"]:::data
        MoviesService["movies.service.ts"]:::data
        MoviesInterface["movies.interface.ts"]:::data
    end

    %% External Systems
    ExternalAPI["External Movies API"]:::external

    %% Build & Dev Toolchain
    subgraph "Toolchain"
        direction TB
        TSCompiler["TypeScript Compiler\n(tsconfig*.json)"]:::tool
        Vite["Vite Dev Server & Bundler\n(vite.config.mts)"]:::tool
        Dist["dist/"]:::tool
    end

    %% Static Assets
    Public["public/"]:::assets
    Assets["src/assets/"]:::assets

    %% Flows
    MainTs --> AppVue
    AppVue --> PluginsIndex
    PluginsIndex --> VuetifyPlugin
    AppVue --> Router
    Router --> AdminLayout
    Router --> MoviesLayout
    AdminLayout --> MoviesAdminPage
    MoviesLayout --> MoviesListPage
    MoviesAdminPage --> UseMoviesAdminPage
    MoviesListPage --> UseMoviesListPage
    MoviesAdminPage --> HelloWorld
    MoviesListPage --> HelloWorld
    MoviesAdminPage <--> Pinia
    MoviesListPage <--> Pinia
    UseMoviesAdminPage --> Pinia
    UseMoviesListPage --> Pinia
    MoviesAdminPage --> MoviesService
    MoviesListPage --> MoviesService
    MoviesService --> BaseApi
    BaseApi --> ExternalAPI
    MoviesService --> MoviesInterface
    Assets -.-> AppVue
    Public -.-> Dist
    MainTs --> TSCompiler
    TSCompiler --> Vite
    Vite --> Dist

    %% Click Events
    click MainTs "https://github.com/andycodev/movies-frontend/blob/master/src/main.ts"
    click AppVue "https://github.com/andycodev/movies-frontend/blob/master/src/App.vue"
    click Router "https://github.com/andycodev/movies-frontend/blob/master/src/router/index.ts"
    click PluginsIndex "https://github.com/andycodev/movies-frontend/blob/master/src/plugins/index.ts"
    click VuetifyPlugin "https://github.com/andycodev/movies-frontend/blob/master/src/plugins/vuetify.ts"
    click AdminLayout "https://github.com/andycodev/movies-frontend/blob/master/src/layouts/AdminLayout.vue"
    click MoviesLayout "https://github.com/andycodev/movies-frontend/blob/master/src/layouts/MoviesLayout.vue"
    click MoviesAdminPage "https://github.com/andycodev/movies-frontend/blob/master/src/pages/movies/movies-admin/MoviesAdminPage.vue"
    click UseMoviesAdminPage "https://github.com/andycodev/movies-frontend/blob/master/src/pages/movies/movies-admin/useMoviesAdminPage.ts"
    click MoviesListPage "https://github.com/andycodev/movies-frontend/blob/master/src/pages/movies/movies-list/MoviesListPage.vue"
    click UseMoviesListPage "https://github.com/andycodev/movies-frontend/blob/master/src/pages/movies/movies-list/useMoviesListPage.ts"
    click HelloWorld "https://github.com/andycodev/movies-frontend/blob/master/src/components/HelloWorld.vue"
    click BaseApi "https://github.com/andycodev/movies-frontend/blob/master/src/api/baseApi.ts"
    click MoviesService "https://github.com/andycodev/movies-frontend/blob/master/src/services/movies/movies.service.ts"
    click MoviesInterface "https://github.com/andycodev/movies-frontend/blob/master/src/interfaces/movies/movies.interface.ts"
    click Public "https://github.com/andycodev/movies-frontend/tree/master/public/"
    click Assets "https://github.com/andycodev/movies-frontend/tree/master/src/assets/"
    click TSCompiler "https://github.com/andycodev/movies-frontend/blob/master/tsconfig.json"
    click TSCompiler "https://github.com/andycodev/movies-frontend/blob/master/tsconfig.app.json"
    click TSCompiler "https://github.com/andycodev/movies-frontend/blob/master/tsconfig.node.json"
    click Vite "https://github.com/andycodev/movies-frontend/blob/master/vite.config.mts"

    %% Styles
    classDef entry fill:#f9f,stroke:#333,stroke-width:1px
    classDef routing fill:#bbf,stroke:#333,stroke-width:1px
    classDef plugin fill:#ffd,stroke:#333,stroke-width:1px
    classDef ui fill:#afa,stroke:#333,stroke-width:1px
    classDef logic fill:#fea,stroke:#333,stroke-width:1px
    classDef state fill:#fcf,stroke:#333,stroke-width:1px
    classDef data fill:#faa,stroke:#333,stroke-width:1px
    classDef external fill:#ccf,stroke:#333,stroke-width:1px
    classDef tool fill:#ddd,stroke:#333,stroke-width:1px
    classDef assets fill:#eef,stroke:#333,stroke-width:1px
```
