WordPress-iOS
                                
                                
                                
                                    WordPress-iOS copied to clipboard
                            
                            
                            
                        Stats Insights: Optimize table view updates by integrating diffable data source
Use a diffable data source within Stats Insights to make table view cell reloads more efficient. More information about implementation in: https://github.com/wordpress-mobile/WordPress-iOS/pull/22542
To test:
- Open Stats Insights
 - Confirm data loads correctly without flickering
 
Regression Notes
- Potential unintended areas of impact
 
Breaking loading of data within existing Stats Insights.
- What I did to test those areas of impact (or what existing automated tests I relied on)
 
- Manual testing
 SiteStatsInsightsViewModelTestsshould still succeed
- What automated tests I added (or what prevented me from doing so)
 
PR submission checklist:
- [x] I have completed the Regression Notes.
 - [x] I have considered adding unit tests for my changes.
 - [x] I have considered adding accessibility improvements for my changes.
 - [x] I have considered if this change warrants user-facing release notes and have added them to 
RELEASE-NOTES.txtif necessary. 
Testing checklist:
- [ ] WordPress.com sites and self-hosted Jetpack sites.
 - [ ] Portrait and landscape orientations.
 - [ ] Light and dark modes.
 - [ ] Fonts: Larger, smaller and bold text.
 - [ ] High contrast.
 - [ ] VoiceOver.
 - [ ] Languages with large words or with letters/accents not frequently used in English.
 - [ ] Right-to-left languages. (Even if translation isn’t complete, formatting should still respect the right-to-left layout)
 - [ ] iPhone and iPad.
 - [ ] Multi-tasking: Split view and Slide over. (iPad)
 
| 1 Warning | |
|---|---|
| :warning: | This PR is larger than 500 lines of changes. Please consider splitting it into smaller PRs for easier and faster reviews. | 
Generated by :no_entry_sign: Danger
📲 You can test the changes from this Pull Request in Jetpack Alpha by scanning the QR code below to install the corresponding build.
| App Name |   Jetpack Alpha | 
|
| Configuration | Release-Alpha | |
| Build Number | pr22592-3c87ba7 | |
| Version | 24.6 | |
| Bundle ID | com.jetpack.alpha | |
| Commit | 3c87ba7cb5e3609c49150a5b4bc4e66533477f95 | |
| App Center Build | jetpack-installable-builds #8456 | 
📲 You can test the changes from this Pull Request in WordPress Alpha by scanning the QR code below to install the corresponding build.
| App Name |   WordPress Alpha | 
|
| Configuration | Release-Alpha | |
| Build Number | pr22592-3c87ba7 | |
| Version | 24.6 | |
| Bundle ID | org.wordpress.alpha | |
| Commit | 3c87ba7cb5e3609c49150a5b4bc4e66533477f95 | |
| App Center Build | WPiOS - One-Offs #9413 | 
| Warnings | |
|---|---|
| :warning: | PR has more than 500 lines of code changing. Consider splitting into smaller PRs if possible. | 
Generated by :no_entry_sign: dangerJS
@guarani review for this can wait after we're done with Traffic tab.
I added Stats Insights Details support in this PR. Stats Period Details is implemented in https://github.com/wordpress-mobile/WordPress-iOS/pull/22823.
These two PRs should cover diffable data source support for all the Stats.
Related to the failing CI checks: https://a8c.slack.com/archives/C05N140C8H5/p1710357494940709
I moved this to a new GitHub project, more context here: p1710464002701159-slack-C06BR07TJHK
TODO: Requires the same fix https://github.com/wordpress-mobile/WordPress-iOS/pull/22857
Done: