-
Type:
Task
-
Resolution: Done
-
Priority:
Blocker
-
Affects Version/s: None
-
None
-
HWC Sprint 17, HWC Sprint 18
Currently, APIs are being triggered multiple times when the user navigates back to a screen. Every time the screen is revisited, all associated APIs are called again, even if the data has already been fetched. There is no existing validation, caching, or state retention mechanism to reuse previously loaded data.
This results in redundant network calls, unnecessary server load, and repeated loading states that negatively impact app performance and user experience.
Impact
- Increased and unnecessary network traffic
- Higher server load
- Slower screen load times and reduced app responsiveness
- Inconsistent user experience due to repeated loading indicators
Expected Behavior
- APIs should be called only once when the data is initially required
- Previously fetched data should be reused when navigating back to the screen
- Back navigation should not trigger fresh API calls unless data is explicitly invalidated
Acceptance Criteria
- API calls are made only if data is not already available
- Data is retained in memory / ViewModel / cache across navigation events
- Navigating back to the screen does not re-trigger API calls
- Loading state is not shown again if valid data already exists
- Configuration changes (e.g., rotation) do not re-trigger API calls