Thread
#compose
    Andrey Kulikov

    Andrey Kulikov

    2 years ago
    Note that
    Flow
    integration should work fine with dev10 if you want to try it. unfortunately we didn't merge the adapter before the build cut, so it will be added in dev11. but feel free to temporary copy it from here and play with it
    Sinan Kozak

    Sinan Kozak

    2 years ago
    Will we able to use flow directly or will we still need a Model object with annotation?
    Andrey Kulikov

    Andrey Kulikov

    2 years ago
    the method will return you a State object. you don't need to create your class. you can take a look on a sample here https://android-review.googlesource.com/c/platform/frameworks/support/+/1287599/21/compose/compose-runtime/samples/src/main/java/androidx/compose/samples/FlowAdapterSamples.kt
    flosch

    flosch

    2 years ago
    @Andrey Kulikov It might make sense to also provide a state flow extension in the future since it implicitly has an initial state
    Andrey Kulikov

    Andrey Kulikov

    2 years ago
    sure, once we update to the coroutines version where it will be available
    Sinan Kozak

    Sinan Kozak

    2 years ago
    Ohh sample is great. So we will be able to have our ui state on flow and convert to it Compose State. Sounds awesome 😄