bluelinelabs / Conductor

A small, yet full-featured framework that allows building View-based Android applications
Apache License 2.0
3.89k stars 342 forks source link

Jetpack Compose + Conductor. #605

Closed xpnewmedia closed 3 years ago

xpnewmedia commented 4 years ago

It's been a little bit since digging back into Android Development.

When I left off Conductor was new and trending, and I used it in a number of projects with somewhat ease, I get the concept.

Now with Jetpack Compose, which i'm currently wrapping my head around...

Is there room in an Android App's Architecture to include both strategies....or Is it one or the other.

TY

StephanSchuster commented 3 years ago

I would also be very interested in the communities' opinion if/how Jetpack Compose and Conductor could play together nicely.

PaulWoitaschek commented 3 years ago

I implemented the basic support with instant and view state restoration in this branch: https://github.com/bluelinelabs/Conductor/tree/compose_support

You can find a ComposeController here: https://github.com/bluelinelabs/Conductor/blob/compose_support/demo/src/main/java/com/bluelinelabs/conductor/demo/controllers/ComposeController.kt

The basic building block is this: https://github.com/bluelinelabs/Conductor/blob/compose_support/conductor/src/main/java/com/bluelinelabs/conductor/internal/OwnViewTreeLifecycleAndRegistry.kt

The saved state registry depend on you using an AppCompatActivity of a recent version

PaulWoitaschek commented 3 years ago

Released as 3.1.0!