How midudev/esland-web works
Main System Components
a) Frontend Layer
• Static Site Generation (Astro)
• Client-side Components (React/Astro)
• Internationalization System
• Asset Management
b) API Layer
• REST Endpoints (/api/*)
• Voting System
• Gallery Management
• Candidates Management
c) External Services
• Twitch Integration
• Database Connection (for voting system)
Specific Component Details
Frontend Components:
• Pages Module (src/pages/*)
• Components Module (src/components/*)
• i18n System (src/i18n/*)
• Hooks Layer (src/hooks/*)
• Layout System (src/layouts/*)
API Components:
• Voting API (src/pages/api/vote.ts)
• Gallery API (src/pages/api/gallery.json.ts)
• Candidates API (src/pages/api/candidates.json.ts)
Data Management:
• Database Client (src/db/client.ts)
• Schema Definitions (src/schemas/*)
• Type Definitions (src/types/*)
Relationships and Data Flow
• Client-side routing flows
• API request/response paths
• Data flow between components
• i18n content distribution
• Asset loading paths
Technical Stack Indicators
• Astro
• TypeScript
• Tailwind CSS
• Bun/PNPM
• Database system
Additional Elements
• Build Configuration (astro.config.mjs, tailwind.config.mjs)
• Environment Configuration (.env)
• Script Utilities
• Public Assets Management
Remember to highlight the multi-language support as it's a key feature, showing how content flows through the i18n system to different language versions of the pages.