Apr 24, 2025 · 2 min read · Flow vs Stateflow vs Sharedflow First, the Base Type: Flow<T> A cold asynchronous stream. Starts emitting only when collected. Use for standard data streams (e.g., database queries, API paginated responses). fun getNumbers(): Flow<Int> = flow { ...
Join discussion
Mar 9, 2024 · 4 min read · Background Android development often involves complex state management and repetitive UI updates. ViewModels offer such structure and testability to address these challenge and many others. With LiveData, UI changes automatically synchronizes with Vi...
Join discussion
Jun 7, 2022 · 2 min read · If you are getting tired by reading all the stuff on the internet related state flow and shared flow and want to know what they actually are then in this blog I have shared some easy understanding of it and check out all the code snippets for better ...
Join discussion