# geovanamat/frieren-landing-page architecture

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

- Interactive diagram: https://gitdiagram.com/geovanamat/frieren-landing-page
- Repository: https://github.com/geovanamat/frieren-landing-page

## Overview

##### Project type and purpose
- This is a front-end, single-page “landing page” application built with React, TypeScript and Vite.
- It has no backend or database: it’s intended to be built into static assets and served from a static host or CDN.

##### File structure
- Top-level:
- package.json / package-lock.json – dependencies and scripts
- vite.config.ts – Vite build/dev server configuration
- tsconfig*.json – TypeScript compiler settings
- public/ – static host-root files (e.g., favicon, images)
- src/ – application source
- src/ subdirectories:
- components/ui/ – reusable React UI components (Banner, NavBar, cards, galleries)
- assets/ – image and media files referenced by components
- lib/utils.ts – shared helper functions
- App.tsx, main.tsx – application entry point and root component
- index.css – global styles
- Build & lint:
- eslint.config.js – project lint rules
- vite-env.d.ts – Vite runtime typings

##### Extract insights from README
- Uses Vite dev server for HMR (Hot Module Replacement) via either Babel or SWC plugin
- TypeScript + React with minimal template
- Default dev port 5173
- Encourages expanding ESLint for production

- a. Main components
- Developer workstation (Node.js + npm)
- Vite CLI & dev server + React plugin (Babel or SWC)
- TypeScript compiler integration
- Source code (src folder: components, assets, utils)
- Public folder (static entry point files)
- Browser (runs final JS/CSS)
- Optional: CI/CD or static hosting (e.g., Netlify, Vercel, GitHub Pages)
- b. Relationships & interactions
1. Developer invokes npm run dev or npm run build
2. Vite reads vite.config.ts, tsconfig.json, eslint.config.js
3. Vite plugin-react transforms TSX → JavaScript (via Babel or SWC)
4. TypeScript checks types during transform
5. Vite bundles modules, injects HMR code (dev)
6. public/index.html is the HTML shell; bundles and assets are injected
7. Browser requests index.html → dev server serves in memory (dev) or loads static files from dist/ (prod)
8. React hydrates `<App />`, which imports ui components, CSS, images from src
- c. Architectural patterns & principles
- Component-based UI: each UI widget in src/components/ui
- Single-page application (SPA) served from a single HTML shell
- Build pipelining: unbundled dev server + on-the-fly transforms vs. production bundling
- Separation of concerns: assets, utils, components, config
- d. Key technologies
- React 18 (JSX/TSX)
- TypeScript
- Vite (esbuild powered dev server, Rollup for prod)
- @vitejs/plugin-react (Babel or SWC)
- ESLint (ts-eslint.config, optional react-x/dom plugins)

## Diagram (Mermaid)

```mermaid
flowchart TB
    %% Developer Workstation
    subgraph "Developer Workstation"
        DevCLI["Developer CLI<br/>(Node.js + npm)"]:::dev
    end

    %% Development Mode
    subgraph "Development Mode"
        DevCLI -->|"npm run dev"| ViteDev["Vite Dev Server"]:::dev
        ViteDev -->|"reads"| ViteConfig["vite.config.ts"]:::dev
        ViteDev -->|"reads"| TSConfig["tsconfig.json / tsconfig.app.json / tsconfig.node.json"]:::dev
        ViteDev -->|"reads"| ESLint["eslint.config.js"]:::dev
        ViteDev -->|"uses plugin"| ReactPlugin["@vitejs/plugin-react<br/>(Babel/SWC)"]:::dev
        ReactPlugin -->|"transforms"| TSCompiler["TypeScript Compiler"]:::dev
        TSCompiler -->|"type checks"| Source["Source Code<br/>(src)"]:::app
        Source --> AppEntry["src/main.tsx"]:::app
        AppEntry --> AppRoot["src/App.tsx"]:::app
        AppRoot --> UIComp["src/components/ui"]:::app
        UIComp --> Asym["AsimetricPhotos.tsx"]:::app
        UIComp --> Banner["Banner.tsx"]:::app
        UIComp --> Card["CardPersonagem.tsx"]:::app
        UIComp --> NavBar["NavBar.tsx"]:::app
        UIComp --> Galeria["SecaoGaleria.tsx"]:::app
        UIComp --> Personagens["SecaoPersonagens.tsx"]:::app
        AppRoot --> Utils["src/lib/utils.ts"]:::app
        AppRoot --> Styles["src/index.css"]:::app
        AppRoot --> Assets["src/assets"]:::app
        AppRoot --> ViteEnv["src/vite-env.d.ts"]:::app
        ViteDev -->|"serves in-memory"| HTML["public/index.html"]:::app
        ViteDev -->|"HMR update"| Browser["Browser"]:::runtime
        HTML --> Browser
        Source --> Browser
    end

    %% Production Mode
    subgraph "Production Build"
        DevCLI -->|"npm run build"| ViteBuild["Vite Build Pipeline<br/>(Rollup)"]:::dev
        ViteBuild -->|"reads"| ViteConfig
        ViteBuild -->|"reads"| TSConfig
        ViteBuild -->|"reads"| ESLint
        ViteBuild -->|"uses plugin"| ReactPlugin
        ViteBuild -->|"transforms & bundles"| Dist["dist/"]:::app
        Dist -->|"deployed to"| StaticHost["Static Host<br/>(Netlify, Vercel)"]:::runtime
        StaticHost --> Browser
    end

    %% Other Config Files
    subgraph "Configs & Metadata"
        Lockfile["package-lock.json"]:::dev
        Gitignore[".gitignore"]:::dev
        Readme["README.md"]:::dev
    end

    %% Click Events
    click DevCLI "https://github.com/geovanamat/frieren-landing-page/blob/main/package.json"
    click ViteConfig "https://github.com/geovanamat/frieren-landing-page/blob/main/vite.config.ts"
    click TSConfig "https://github.com/geovanamat/frieren-landing-page/blob/main/tsconfig.json"
    click ESLint "https://github.com/geovanamat/frieren-landing-page/blob/main/eslint.config.js"
    click HTML "https://github.com/geovanamat/frieren-landing-page/blob/main/index.html"
    click UIComp "https://github.com/geovanamat/frieren-landing-page/tree/main/src/components/ui/"
    click Asym "https://github.com/geovanamat/frieren-landing-page/blob/main/src/components/ui/AsimetricPhotos.tsx"
    click Banner "https://github.com/geovanamat/frieren-landing-page/blob/main/src/components/ui/Banner.tsx"
    click Card "https://github.com/geovanamat/frieren-landing-page/blob/main/src/components/ui/CardPersonagem.tsx"
    click NavBar "https://github.com/geovanamat/frieren-landing-page/blob/main/src/components/ui/NavBar.tsx"
    click Galeria "https://github.com/geovanamat/frieren-landing-page/blob/main/src/components/ui/SecaoGaleria.tsx"
    click Personagens "https://github.com/geovanamat/frieren-landing-page/blob/main/src/components/ui/SecaoPersonagens.tsx"
    click AppEntry "https://github.com/geovanamat/frieren-landing-page/blob/main/src/main.tsx"
    click AppRoot "https://github.com/geovanamat/frieren-landing-page/blob/main/src/App.tsx"
    click Utils "https://github.com/geovanamat/frieren-landing-page/blob/main/src/lib/utils.ts"
    click Assets "https://github.com/geovanamat/frieren-landing-page/tree/main/src/assets/"
    click Styles "https://github.com/geovanamat/frieren-landing-page/blob/main/src/index.css"
    click ViteEnv "https://github.com/geovanamat/frieren-landing-page/blob/main/src/vite-env.d.ts"
    click Gitignore "https://github.com/geovanamat/frieren-landing-page/blob/main/.gitignore"
    click Lockfile "https://github.com/geovanamat/frieren-landing-page/blob/main/package-lock.json"
    click Readme "https://github.com/geovanamat/frieren-landing-page/blob/main/README.md"

    %% Styles
    classDef dev fill:#D6E5FF,stroke:#333,stroke-width:1px
    classDef app fill:#DFFFE0,stroke:#333,stroke-width:1px
    classDef runtime fill:#FFE7C0,stroke:#333,stroke-width:1px
```
