How adilououssei/myhospital-mobile works
MyHospital is a French-language mobile health app. Users can authenticate, find doctors and care facilities, book and manage consultations, and access health, profile, pharmacy, and support features. The sampled code confirms app initialization and session restoration, appointment retrieval and evaluation loading, and service calls to the backend. Several screens and service modules are present in the tree but their wiring was not sampled, so their links are omitted where uncertain.
Main entry points: App.tsx App shell · api.config.ts API client · RootNavigator.tsx Root navigation · AppointmentsScreen.tsx Appointments
Components 26
App and navigation
- App shell
App.tsx - Root navigation
app/navigation/RootNavigator.tsx - Auth stack
app/navigation/AuthStack.tsx - Main tabs
app/navigation/MainTabs.tsx
Care and appointments
- Doctor directory
app/components/DoctorsDirectoryScreen.tsx - Doctor details
app/components/DoctorDetailScreen.tsx - Booking choices
app/components/BookingTypeScreen.tsx - Appointments
app/components/AppointmentsScreen.tsx - Video consultation
app/components/VideoCallScreen.tsx - Hospitals
app/components/HospitalScreen.tsx - Pharmacies
app/components/PharmacyScreen.tsx
Account and health
- Login and signup
app/components/LoginScreen.tsx - Patient profile
app/components/ProfileScreen.tsx - Health information
app/components/HealthInfoScreen.tsx - Notifications
app/components/NotificationsScreen.tsx
Services and integrations
- On-call pharmacy data
useOnCallPharmacies.ts - Notification state
app/context/NotificationContext.tsx - Appointment service
app/services/rendezvous.service.ts - Evaluation service
app/services/evaluation.service.ts - Authentication service
app/services/authService.ts - Profile service
app/services/profileService.ts - API client
app/services/api.config.ts - Local token storage
app/services/secureStorage.ts
Other components
- Patient
- Health backend
- Device storage
Connections 24
- Patient → App shell: opens
- App shell → Root navigation: renders
- Root navigation → Auth stack: routes unauthenticated
- Root navigation → Main tabs: routes authenticated
- Auth stack → Login and signup: shows
- Patient → Doctor directory: browses
- Patient → Appointments: manages
- Patient → Hospitals: finds care
- Patient → Pharmacies: finds pharmacies
- Patient → Patient profile: manages account
- Patient → Health information: views
- Patient → Notifications: checks
- Appointments → Appointment service: loads appointments
- Appointments → Evaluation service: loads pending evaluations
- Notification state → Appointment service
- App shell → Local token storage: restores session
- App shell → Device storage: reads saved user
- Authentication service → API client: sends auth requests
- Appointment service → API client: sends appointment requests
- Profile service → API client: sends profile requests
- API client → Health backend: requests data
- On-call pharmacy data → Health backend: fetches pharmacy data
- On-call pharmacy data → Device storage: loads and saves favorites
- Notification state → Health backend: requests unread count