Skip to content

Migrate LiveData to Kotlin Flows #54

Description

@hrodrick

As discussed on the Android's Roundtable of 01/12/2021 it seems good to migrate the current LiveData implementations to Kotlin flows, which is the new official way of sharing reactive information between activities and viewmodels.

It brings many benefits like chaining operations, cold and hot flows, defining when we want to react to changes (for example, if we want to react only when the view is resumed or when it is started), independence from Android (we can use it in MPP projects), etc.

As an additional point new libraries built on kotlin are recommended to use with Flows, an example of it is the Android architecture's Paging Library.

Kotlin flows on Android : https://developer.android.com/kotlin/flow

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions