Simplifying DiffUtil with RxJava
Saket Narayan saket.me
One of my favorite parts of RxJava is that no matter how complex a state management usecase is, there’s always an operator for that. During a recent code cleanup, I found a very cool usecase of RxJava’s scan() and compose() operators for simplifying the usually verbose DiffUtil implementation.
I had been delaying writing this post for a while, but Mark Allison’s new series of articles on adding item change animations to RecyclerView have finally pushed me to finish this.
More ways to use this
Open on another device
Scan to open this page. Your saved notes and account access are not included.