How 31133498/ilmeen works
Project type and purpose
• This is a full-stack web project with two main halves:
• A React/Vite-powered static landing page (written in TypeScript, under src/ + public/)
• A Django REST API backend (under backend/, with core/ and users/ apps)
• The landing page is deployed to Vercel as a static site, while the backend runs as a separate server talking to a relational database.
File structure
• Top-level directories:
• backend/ → Django project and apps (core, users), manage.py, settings, URLs, migrations
• public/ → static assets (images, optional recitation.mp3), served directly
• src/ → React/Vite app (App.tsx, components, styling)
• scripts/ → helper for downloading remote assets
• Configuration files: package.json, tsconfig.json, vercel.json, backend/requirements.txt
• Patterns:
• Django’s MVC-style (models, serializers, views, URLs)
• React component hierarchy under src/components
• Static-asset pipeline via Vite → dist/ → Vercel
Main system components
• End-user’s Browser
• Vercel Static Hosting (serves the compiled React app from dist/)
• React Frontend (UI, audio toggle, responsive sections: Hero, Problem/Solution, CTA, etc.)
• Public Assets (images in public/assets or remote Unsplash URLs; optional recitation.mp3)
• Django Backend Server
• ASGI/WSGI entrypoints (asgi.py, wsgi.py)
• core app (models, serializers, views, URLs)
• users app (authentication, signals, serializers, views)
• Relational Database (PostgreSQL/MySQL/SQLite configured in settings.py)
• External CDN (Unsplash for remote images)
• Build & Deployment Tools (npm/Vite, pip, PowerShell script, Vercel)
Relationships and data flows
• Browser → Vercel: HTTP GET index.html + JS/CSS bundles → React app boots
• React app → public/assets or Unsplash: loads images and audio
• React app (optionally) → Django API endpoints at /api/core/ and /api/users/ (via fetch/Axios)
• Django → Database: read/write core and user data
• scripts/download-assets.ps1 → populates public/assets before build
• npm run build → dist/ → deployed by Vercel
• pip install & manage.py migrate → backend database schema
Architectural patterns & design principles
• Separation of concerns:
• Frontend SPA vs. backend REST API
• Static asset hosting vs. dynamic data service
• Component-based design in React (reusable UI sections)
• Django’s MVC (models, serializers, views, URL routing)
• Infrastructure as code: vercel.json for static site routing/build config
• Mobile-first responsive layout in CSS (App.css, style.css)