Caregiver Store
Component Detail
Data Layer
low complexity
mobile
0
Dependencies
2
Dependents
2
Entities
0
Integrations
Description
Local state management and caching layer for caregiver records using Riverpod. Stores caregiver lists keyed by contact ID, handles optimistic updates on create/edit/delete, and exposes reactive streams so the UI rebuilds automatically when caregiver data changes.
caregiver-store
Responsibilities
- Cache caregiver records per contact ID
- Provide reactive state streams for UI consumption
- Handle optimistic updates and rollback on API failure
- Synchronize local state with REST API responses
Interfaces
watchCaregivers(contactId): Stream<List<Caregiver>>
addCaregiverLocally(caregiver)
updateCaregiverLocally(caregiver)
removeCaregiverLocally(caregiverId)
refreshCaregivers(contactId)
clearCache(contactId)
Relationships
Dependents (2)
Components that depend on this component
Related Data Entities (2)
Data entities managed by this component