How ishaan-mit/a4-sleeptracker works
Sleeptracker is an Ionic/Angular sleep log intended to record overnight sleep and daytime sleepiness and let users view both. The runtime path bootstraps the app, routes to the home page, and exposes sleep data through a service that keeps entries in in-memory arrays; the service also seeds example entries. The README identifies logging and viewing as product capabilities, but the shown home-page code only exposes a data getter, so entry controls and their wiring are not evidenced here.
Main entry points: sleep.service.ts Sleep service · home.page.ts Home page · main.ts App bootstrap · app.routes.ts Home routing
Components 9
Application shell
- App bootstrap
sleeptracker/src/main.ts - App shell
sleeptracker/src/app/app.component.ts - Home routing
sleeptracker/src/app/app.routes.ts
Sleep experience
- Home page
sleeptracker/src/app/home/home.page.ts
Sleep data
- Sleep service
sleeptracker/src/app/services/sleep.service.ts - Sleep data base
sleeptracker/src/app/data/sleep-data.ts - Overnight sleep entry
sleeptracker/src/app/data/overnight-sleep-data.ts - Sleepiness entry
sleeptracker/src/app/data/stanford-sleepiness-data.ts
Other components
- Sleep tracker user
Connections 9
- App bootstrap → App shell: bootstraps
sleeptracker/src/main.ts - App bootstrap → Home routing: registers
sleeptracker/src/main.ts - Home routing → Home page: loads
sleeptracker/src/app/app.routes.ts - Sleep tracker user → Home page: uses
readme.txt - Home page → Sleep service: reads data
sleeptracker/src/app/home/home.page.ts - Sleep service → Overnight sleep entry: creates entries
sleeptracker/src/app/services/sleep.service.ts - Sleep service → Sleepiness entry: creates entries
sleeptracker/src/app/services/sleep.service.ts - Overnight sleep entry → Sleep data base: extends
sleeptracker/src/app/data/overnight-sleep-data.ts - Sleepiness entry → Sleep data base: extends
sleeptracker/src/app/data/stanford-sleepiness-data.ts