How domthor/risk-radar works
Main Components
• Frontend – The client-side interface built with React using Vite and styled with Tailwind CSS. It’s organized into pages (e.g., About, Alerts, Score, Search, Settings) and multiple reusable components (such as Navbar, Autocomplete, BarCard, PieCard, RecentEventsCard, etc.). The frontend also has hook files for managing state (e.g., useCounties, useData) and configuration files like vite.config.js and ESLint settings.
• Backend – A Flask-based API server that handles API requests. The code is in app.py with additional configuration and dependency files (requirements.txt, vercel.json, and a separate instance folder for the database).
• Database – SQLite stored within the backend’s instance folder, utilized via Flask-SQLAlchemy.
Architectural Patterns and Design Principles
• Deployment Considerations – With vercel.json files present in both the backend and frontend, note that deployment may be planned to Vercel, so consider illustrating the deployment space as a cloud environment if desired.
• Use clear labels for each component or module: “React Frontend,” “Flask API Backend,” and “SQLite Database.”
• Annotations briefly specifying frameworks or tools (e.g., “Vite + React”, “Flask + Flask-SQLAlchemy”, “SQLite”).