Skip to content

Releases: badoo/Decompose

0.4.0

13 Oct 19:11
f2d9178
Compare
Choose a tag to compare
  • Added Router.bringToFront extension function (#208)
  • Expose BackPressedHandler from ComponentContext, ComponentContext.backPressedDispatcher is now deprecated (#212)
  • Avoid saving configurations in Children functions (#213)
  • Minor API fixes in extensions-android module (#216)
  • Update documentation about extensions-android module (#218)
  • Added RouterState constructor overload (#220)
  • Clean-up deprecated code (#241)
  • Check configuration uniqueness in Router (#244)
  • Enabled Apple silicon targets (#246)
  • Removed RouterFactory interface (#251)
  • Removed Navigator interface (#252)
  • Moved Router to router sub-package (#253)
  • Added lifecycle argument to ComponentContext.childContext extension function (#254)
  • Updated Kotlin to 1.5.30, Jetpack and JetBrains Compose to 1.0.3 and 1.0.0-alpha4-build348 (#234)
  • Fixed a memory leak in MergedLifecycle (#238)
  • Add documentation for navigation, extension functions, and hierarchy (#219 by @plusmobileapps)
  • Additional documentation updates (#215, #218, #222 by @moffpage, #233 by @Morfly)

Breaking changes

This release brings various API changes:

  • ComponentContext now exposes backPressedHandler property, the backPressedDispatcher property is deprecated (motivation: #205, pull-request: #212)
  • There were minor API fixes in extensions-android module (pull-request: #216), please check the updated documentation (pull-request: #218)
  • All previously deprecated code with WARNING level now has ERROR level, all previously deprecated code with ERROR level is removed (pull-request #241)
  • The Router now checks that all configurations are unique (as per the documentation), and throws an error if this is not the case (pull-request #244)
  • The RouterFactory interface is removed and is no longer extended by ComponentContext, its router(...): Router method is now an extension function (pull-request #251)
  • The Navigator interface is removed, the Router interface is now responsible for navigation
  • The Router and its surroundings are moved from com.arkivanov.decompose to com.arkivanov.decompose.router package (pull-request: #253)
  • Added lifecycle argument to ComponentContext.childContext extension function, with default value being null (motivation: #227, pull-request: #254)

The documentation is updated to reflect all the changes.

Migration

You can use the attached script in the "Assets" section of this release, which updates imports in Kotlin files recursively, due to Router moved to the router sub-package.

0.3.1

04 Aug 20:14
1950a78
Compare
Choose a tag to compare
  • Update Essenty to 0.1.2 to allow testing components with Routers in unit tests (#202)

0.3.0

01 Aug 23:36
71231b4
Compare
Choose a tag to compare
  • Used Essenty library, removed Parcelable, @Parcelize, Lifecycle, StateKeeper, InstanceKeeper and BackPressedDispatcher (#187, #189)
  • Update Jetpack Compose to 1.0.0 and JetBrains Compose to 0.5.0-build253 (#195)
  • Deprecated rememberRootComponent functions (#193)
  • Added LifecycleController @Composable function to extensions-compose-jetbrains (#197)
  • Updated documentation (#191)

Breaking changes

Please familiarise yourself with the updated documentation.

Essenty library

Parcelable, @Parcelize, Lifecycle, StateKeeper, InstanceKeeper, BackPressedDispatcher and related things were extracted to the Essenty library, and so Decompose now depends on Essenty. This change makes Decompose and MVIKotlin compatible. It also allows developers to use Essenty library without any extra dependencies.

0.2.6

03 Jun 20:19
224258c
Compare
Choose a tag to compare
  • Added DefaultComponentContext builders for Android (#162)
  • Fixed packagingOptions in extensions-compose-jetpack module (#163)

0.2.5

02 Jun 23:17
be56233
Compare
Choose a tag to compare
  • Updated Kotlin to 1.5.10, Jetpack Compose to 1.0.0-beta08, JetBrains Compose to 4.0.0 (#160)
  • Added watchos targets (#156 by @plusmobileapps)
  • Added ensureNeverFrozen to mutable classes (#145)
  • Added Children function overloads with RouterState argument (#146)
  • Deprecated @Composable fun Value.asState(): State, introduced @Composable fun Value.subscribeAsState(): State (#134)
  • Fixed crossfade does not preserve state (#137)

0.2.4

26 Apr 18:58
5f6042d
Compare
Choose a tag to compare
  • Updated Jetpack Compose to 1.0.0-beta05 and JetBrains Compose to 0.4.0-build184 (#120)

0.2.3

16 Apr 00:05
efa62ba
Compare
Choose a tag to compare

Fix Compose UI state not restored on configuration change with animations (#117)

0.2.2

15 Apr 22:22
7f8f31e
Compare
Choose a tag to compare
  • Fix Compose UI state not restored on configuration change (#115)

0.2.1

29 Mar 22:47
79ac94d
Compare
Choose a tag to compare
  • Updated Kotlin to 1.4.31, Jetpack Compose to 1.0.0-beta03 and JetBrains Compose to 0.4.0-build177 (#108)
  • Fixed wrong animation direction when top child is replaced (#107)

0.2.0

28 Mar 13:31
08771e6
Compare
Choose a tag to compare
  • Starting from this release Decompose is published to Maven Central
  • Added experimental animations API (Breaking: the Children(..., animation, ...) argument's signature is changed, the callback now accepts the whole RouterState instead of just Child.Created) (#94)
  • Enabled IR compiler for JavaScript (#98)
  • Introduced StateKeeper, InstanceKeeper and BackPressedDispatcher builders for AndroidX, deprecated extensions SavedStateRegistry.toStateKeeper, ViewModelStore.toInstanceKeeper and OnBackPressedDispatcher.toBackPressedDispatcher (#87)
  • Added isSavingAllowed predicate to AndroidX StateKeeper builder (#88)
  • Breaking: extracted inner class RouterState.Entry as a top-level class Child, argument Children(..., content) now accepts Child instead of pair Component, Configuration (#91)
  • Relaxed Configuration generic types from Parcelable to Any where possible (#92)
  • Breaking: renamed property Child.Created.component to Child.Created.instance, renamed argument router(..., componentFactory) to router(..., childFactory) (#93)
  • Fixed default InstanceKeeper not being destroyed at the end of lifecycle (#90)
  • Fixed state not being saved in ChildStateKeeper (#95)