How aman-raj-071/airexpo works
AirExpo is an air-quality and respiratory-health dashboard. A user signs in, selects a location, reviews environmental conditions and health guidance, and can plan cleaner routes or configure alerts; signed-in users can save health records and reports to cloud storage. The graph includes documented route, alert, authentication, health, and storage branches. Some feature components and server internals were not excerpted, so their implementation links are omitted where the available evidence does not establish them.
Main entry points: App.tsx Air-quality dashboard · server.ts Express API and monitor · HealthWorkspace.tsx Health workspace · main.tsx Web app routing
Components 29
App entry and identity
- Web app routing
src/main.tsx - Sign-in screen
src/components/AuthPage.tsx - Cognito auth client
src/auth/amplify.ts
Air quality experience
- Air-quality dashboard
src/App.tsx - Environmental data
src/services/openMeteoApi.ts - Live data panels
src/components/OpenMeteoLivePanel.tsx - AQI globe
src/components/AqiGlobe.tsx - Location comparison
src/components/ComparisonMatrix.tsx - AQICN feed panel
src/components/AqicnLivePanel.tsx - Route planner UI
src/components/GoogleJoggingMap.tsx - Route exposure ranking
src/services/routeAirQuality.ts
Health workspace
- Health workspace
src/components/HealthWorkspace.tsx - Health assistant
src/components/HealthAssistant.tsx - Medical reports
src/components/MedicalReportsPanel.tsx - Local health store
src/services/localHealthStore.ts
Server and alerts
- Route and geocode API
routeService.ts - Express API and monitor
server.ts - Browser and SMS alerts
src/components/AirAlerts.tsx - SMS sender
smsAlerts.ts - Diagnostic service
src/services/aiDiagnosticService.ts
Cloud storage
- Cloud storage panel
src/components/CloudStoragePanel.tsx - Cloud API client
src/services/cloudStorage.ts - Express cloud adapter
cloudStorage.ts - Cloud data handler
infra/lambda/cloud.mjs
Other components
- Dashboard user
- Open-Meteo services
- OpenRouteService
- DynamoDB and S3
- AWS SNS
Connections 34
- Dashboard user → Web app routing: opens
src/main.tsx - Web app routing → Sign-in screen: routes to sign-in
src/main.tsx - Web app routing → Air-quality dashboard: opens dashboard
src/main.tsx - Web app routing → Cognito auth client: checks session
src/main.tsx - Sign-in screen → Cognito auth client: authenticates with
src/components/AuthPage.tsx - Air-quality dashboard → Environmental data: searches locations
src/App.tsx - Air-quality dashboard → Live data panels: renders
src/App.tsx - Air-quality dashboard → AQI globe: renders
src/App.tsx - Air-quality dashboard → Location comparison: renders
src/App.tsx - Air-quality dashboard → Route planner UI: renders
src/App.tsx - Air-quality dashboard → Route exposure ranking: ranks alternatives
src/App.tsx - Air-quality dashboard → AQICN feed panel: shows feed
- Live data panels → Open-Meteo services: fetches modeled data
- Environmental data → Open-Meteo services: queries geocoder and weather
- Route planner UI → Express API and monitor: requests routes
- Express API and monitor → Route and geocode API: calls route handler
server.ts - Route and geocode API → OpenRouteService: requests alternatives
routeService.ts - Express API and monitor → Open-Meteo services: serves route samples
server.ts - Browser and SMS alerts → Express API and monitor: configures SMS alerts
- Express API and monitor → SMS sender: sends test SMS
server.ts - SMS sender → AWS SNS: publishes messages
- Air-quality dashboard → Health workspace: opens workspace
src/App.tsx - Health workspace → Health assistant: renders
src/components/HealthWorkspace.tsx - Health workspace → Medical reports: renders
src/components/HealthWorkspace.tsx - Health workspace → Local health store: loads local records
src/components/HealthWorkspace.tsx - Cloud storage panel → Cloud API client: requests storage
src/components/CloudStoragePanel.tsx - Health workspace → Cloud API client: loads and saves records
src/components/HealthWorkspace.tsx - Medical reports → Cloud API client: uses cloud storage
src/components/MedicalReportsPanel.tsx - Cloud API client → Express cloud adapter: calls cloud API
- Express API and monitor → Express cloud adapter: registers adapter
server.ts - Express cloud adapter → Cloud data handler: invokes handler
cloudStorage.ts - Cloud data handler → DynamoDB and S3: reads and writes
- Air-quality dashboard → Diagnostic service: requests explanation
src/App.tsx - Diagnostic service → Express API and monitor: posts diagnosis request
src/services/aiDiagnosticService.ts