Harmony Music: offline-first player patterns
Offline music apps are storage, scanning, and service lifecycle problems. Harmony-style players keep a local library index and a playback service that survives UI navigation.
Patterns
- Scan once, listen to filesystem events later.
- Queue lives in a controller/service, not in a screen widget.
- Platform notification/media sessions are required UX.
Pitfalls
Large libraries need incremental indexing. Do not block first frame on a full SD card scan.
Compare with Spotube if you also need streaming catalogs.