How ntthong0710/medisafe_mobile_app works
Project Type and Purpose
• This project is a full-stack mobile application with a dedicated backend service. The frontend is built using a JavaScript/TypeScript framework (likely React Native, given files like App.js, .tsx components, and navigation-related code) and provides a user interface for interacting with health-related features. The backend (in the medisafe-backend directory) appears to be a Node.js/Express server that handles business logic for health conditions and symptoms, seeds initial data, and potentially exposes RESTful endpoints.
Analyzing the File Structure
• At the root, you have configuration files (e.g., .gitignore, babel.config.js, app.json, tsconfig.json, eas.json, vercel.json) that suggest mobile configuration and deployment settings.
• The "src" directory contains all the mobile client source code:
• "AuthContext.tsx" for state or authentication management.
• "components" directory with UI elements (cards for condition, medication, symptom, notifications, a sidebar).
• "screens" directory with individual views like Home, Login, Register, Profile, and specialized screens (HealthConditionLookup, Medication, SymptomSearch).
• "navigation" directory for routing between screens.
• "services" for handling API calls.
• "store" likely managing state (e.g., with a Redux slice for medication data).
• "utils" for constants and other helper functions.
• The “medisafe-backend” directory includes backend files:
• "server.js" as the entry point.
• Modules such as HealthCondition.js and Symptoms.js that encapsulate business logic.
• "seed.js" for initializing or seeding the data.
• Its own package.json and configuration file (vercel.json) for deployment.
• This structure indicates a clear separation between the mobile front-end and the backend API.