Change Log¶
0.32.0 (2025-08-19)¶
Navigation¶
- Removed
ResultOwner, useNavigationResultRequest,ActivityResultRequestandPermissionResultRequestdirectly - The package of the following classes changed to
com.freeletics.khonshu.activity:ActivityRouteActivityNavigatorActivityResultRequestPermissionResultRequest
Codegen¶
- Compatibility with Metro 0.6.0.
- Replaced Metro
@ContributesGraphExtensionwith the new@GraphExtensionand@ContributesToon the factory interface.
0.31.2 (2025-08-08)¶
Navigation¶
- Throw exception when navigating to a destination with a parent declared in
@NavDestinationthat is not present in the current back stack. This avoids a later exception in theNavHostwhich is harder to debug because of not knowing how the back stack got into this state.
0.31.1 (2025-07-28)¶
Navigation¶
- Fix issue where
NavHostwould not draw the content of a destination until one recomposition happened.
0.31.0 (2025-07-23)¶
Navigation¶
- Updated
com.eygraber:uri-kmpto 0.0.20 and adapted to breaking API change
Codegen¶
- Support FlowRedux 2 by allowing to use
FlowReduxStateMachineFactoryas parameter in annotations. - Replaced
java.io.Closeablewithkotlin.AutoCloseable. If you contributed any closeables into sets so that they are automatically closed when a destination leaves the back stack this needs to be changed to useAutoCloseablenow. - Generated code does not call generated interfaces
Moduleanymore
0.30.0 (2025-06-30)¶
- Updated Kotlin to 2.2.0.
Codegen¶
- Replaced Dagger and Anvil with Metro.
- Removed
AppScopein favor of Metro’sAppScope.
0.29.0 (2024-11-08)¶
Navigation¶
- Replaced
navigateToRootandresetToRootwithswitchBackStackandshowRootwhich have more predictable behavior and won’t throw exceptions when called in certain back stack states. - Renamed
replaceAlltoreplaceAllBackStacks. - Fixed an issue that would cause delayed state updates after a predictive back gesture. These delayed state updates could cause the app to be unresponsive for a moment or that the same back navigation was repeated.
- Removed the deprecated
NavEventNavigator.
Codegen¶
- Remove support for running as an Anvil plugin. Khoshu’s codegen now always needs to be used through KSP.
State Machine¶
- Added Wasm/WASI target.
0.28.3 (2024-08-05)¶
Codegen¶
- Fix crash when
StackSnapshot.entryForis called for the start destination while being on a different back stack. - Fix KSP2 support for version 2.0.0-1.0.23 and newer.
0.28.2 (2024-07-22)¶
Navigation¶
- Avoid composable of previous being re-created at the end of the predictive back animation. This was causing a visible blinking in the UI.
- Fix part of the predictive back animation being run when using 3 button navigation.
0.28.1 (2024-07-19)¶
Navigation¶
- Fix race condition that would cause custom back handling to sometimes not work.
0.28.0 (2024-07-17)¶
Navigation¶
- Implement predictive back support. When predictive back is enabled by setting
android:enableOnBackInvokedCallback="true"in the AndroidManifest, Khonshu will automatically handle back presses with the predictive back animation to the previous destination.
Codegen¶
- Support for KSP2.
0.27.1 (2024-06-21)¶
ActivityRoute.buildIntent()has been changed toActivityRoute.buildIntent(context: Context)to make using it easier.
0.27.0 (2024-06-20)¶
The documentation has been updated.
Navigation¶
- Renamed
ActivityResultNavigatorbase class toActivityNavigatorand movednavigateTo(ActivityRoute)to it. With this change the limitation that anyIntentneeds to useFLAG_ACTIVITY_NEW_TASKis removed. - Removed
ActivityDestination. InsteadActivityRouteimplementations now are building the fullIntent. ForInternalActivityRoutethe route is stillIntentautomatically added to theIntentand theIntentis automatically limited to the current package to prevent hijacking of actions. - Removed the ability to add
ActivityRouteto aDeepLink. The same can be achieved by just launching 2 intents or usingTaskStackBuilder.
0.26.0 (2024-06-12)¶
Navigation¶
- Introduces
HostNavigator. This was previously an internal type used withinNavHostto execute navigation events. It’s now possible to create aHostNavigatorwithrememberHostNavigator(...), pass that instance toNavHostand use it to navigate directly without the use of navigation events. It is safe to referenceHostNavigatoroutside the UI layer. DestinationNavigatoris a replacement forNavEventNavigatorthat delegates toHostNavigator, which means it also works without navigation events. The advantage of using this over usingHostNavigatordirectly is thatDestinationNavigatorsupports activity results, whichHostNavigatordoesn’t.- The
navigate {}function that allows grouping multiple navigation events is now more efficient. TheNavHostwill only be updated once at the end and not between the actions of such a group. NavEventNavigatorwill be removed in one of the next releases.
Codegen¶
- A
HostNavigatoris automatically created in theNavHostActivitycomponent. - It’s required that a
NavRootis provided into the scope of aNavHostActivity. - Each
NavDestinationnow requires anActivityResultNavigatorto be provided into the scope (previouslyNavEventNavigatorwas required).
0.25.0 (2024-05-17)¶
Navigation¶
- Internal improvements on how the back stack is managed.
Codegen¶
- Remove the need to do a lookup for the current destination on the back stack.
- Improve reliability of finding the parent scope on the back stack.
0.24.0 (2024-05-15)¶
Navigation¶
- The
destinationChangedCallbackparameter ofNavHostnow has(NavRoot, BaseRoute) -> Unitsignature, whereNavRootis the current root. If that root is the current destination both parameters are the same. - Khonshu’s own navigation implementation has been moved from
navigation-experimentalinto the mainnavigationartifact. - Removed
navigation-composeartifact that was based on androidx.navigation.
Codegen¶
- The generated component for
@NavHostActivitynow contains the Activity’sIntentinstead of aBundle. - Removed
experimentalNavigationoption and@UseExperimentalNavigation. The generated code will now always use Khonshu’s built-in navigation instead of androidx.navigation. - Updated Anvil to v2.5.0-beta09.
0.23.1 (2024-03-08)¶
Navigation¶
- Fix an issue where
SaveableStateHolderwould not be properly cleared when the destination is removed from the back stack after configuration changes. Thanks to @hoc081098 for the contribution.
Codegen¶
- Add
rememberfor the set of destinations, deep link handlers and deep link prefixes obtained from the generated component, to avoid creating a newNavigationExecutoron re-compositions. - Remove
Experimentalprefix from generated code whenexperimentalNavigationis `true.
0.23.0 (2024-03-01)¶
- Update Compose to 1.6.0
Codegen¶
- Update to Anvil 2.5.0-beta03 and use new
GeneratedFileWithSourcesto support incremental compilation. - When setting
experimentalNavigationin@NavHostActivitytotruethe generated code will contain both the setup for androidx.navigation and experimental navigation. This allows switching between them at runtime. For this it’s required to provide a boolean to theNavHostActivity.scopethat uses@UseExperimentalNavigationas qualifier.
StateMachine¶
- Add
wasmJstarget.
0.22.2 (2024-02-19)¶
Codegen¶
- Fix crash in
StateMachinecollection when lifecycle changes around the same time as the emission of a new state.
0.22.1 (2024-02-16)¶
Codegen¶
- Update
StateMachinecollection to start immediately when the generated composable is added to the composition. Previously this only happened inonResumefor theNavBackStackEntrythat the composable is tied too which caused a visible delay in the content being shown. Whenever the lifecycle is paused afterwards the collection is stopped until the next resume.
0.22.0 (2024-02-02)¶
Navigation¶
- Breaking:
NavDestination,ScreenDestination,OverlayDestination,ActivityDestinationandNavigationSetuphave been moved to thecom.freeletics.khonshu.navigationpackage insidenavigation. Previously these were duplicated betweennavigation-composeandnavigation-experimental. - Breaking: Moved
navigation-composeNavHosttocom.freeletics.khonshu.navigation.androidxandnavigation-experimentalNavHosttocom.freeletics.khonshu.navigation. This now allows to use the AndroidX based and the experimental navigation implementation in the same app and switch between them with a feature flag. - New: Added
replaceAlltoNavEventNavigatorto replace the current back stack including the start destination with the givenNavRoot. Thanks to @hoc081098 for the contribution. - Removed: Deprecated overload of
NavHostthat allowed usingNavRouteas start destination. - Removed:
navigation-fragmentandFragmentnavigation support. - Removed:
navigation-androidxhas been inlined intonavigation-compose.
Codegen¶
- Breaking: The
NavDestinationandNavHostActivityannotations as well asSimpleNavHosthave been moved tocom.freeletics.khonshu.codegen. - Added:
NavHostActivityhas anexperimentalNavigationboolean to generate code with anavigation-experimentalNavHost. - Added:
ActivityScopeand customActivityscopes can now be used asparentScopefor destinations. - Reduce the number of re-compositions in the generated code by remembering the
sendActionlambda. - Generated code for
NavHostActivityis now usingNavHostTransitionAnimations.noAnimations(). - Removed:
@ComposeFragmentDestinationandFragmentcodegen support.
0.21.0 (2023-12-07)¶
- Note:
Fragmentnavigation and codegen have been deprecated and will be removed in the next release. - Updated Kotlin to 1.9.21.
Navigation¶
- Breaking:
navigateBackTo<...>(...)is now an extension method and might need to be explicitly imported. - Breaking: The
Setparameters ofNavHosthave been replaced withImmutableSetto allow the compose compiler to recognize these as immutable. - Breaking: Removed
navControllerparameter fromHavHost. Passing a manually createdNavHostControllerintroduced issues like breaking deep link handling. - New:
NavHost(both the AndroidX and the experimental variant) now supports optionally passing aNavEventNavigator. This can be used instead ofnavControllerto navigate from outside theNavHost(e.g. for bottom navigation). TheNavHosttakes care of callingNavigationSetupfor the passed navigator. - New:
NavHostfromnavigation-experimentalnow also supports passing a Modifier to it. - New: The AndroidX
NavHostwill internally callNavigation.setViewNavControlleron the containerView. This exists primarily for an easier migration fromFragmentnavigation to Compose navigation.
Codegen¶
- New: The
NavHostActivitycodegen now supports passing aModifiertoNavHost. - New: The
NavHostActivitycodegen automatically provides anImmutableSetfor destinations, deep link handlers and deep link prefixes.
0.20.0 (2023-11-17)¶
Navigation¶
- New Add
Modifierparameter toNavHostComposable. - New Add
NavHostoverloaded function that acceptsNavRouteinstead ofNavRoot - New Add optional
transitionAnimationsparameter toNavHostComposable functions. Animations can be overriden withNavHostDefaults.transitionAnimationsor disabled withNavHostTransitionAnimations.noAnimations. Default animations are the same as default animations in AndroidX’sNavHost.
0.19.0 (2023-11-09)¶
Navigation¶
- New: Allow passing an already created
NavControllertoNavHost. This allows controlling the navigation from outside the host, for example from a bottom bavigation or navigation drawer. - Fixed: A crash that happened in
NavHoston re-compositions. - Improved how nav events are collected internally.
Thanks to @hoc081098 and @hoangchungk53qx1 for the contributions.
Codegen¶
- New: Added an
Overlaymarker interface that can be added to routes to indicate to the code generation that this should use anOverlayDestination(DialogDestinationfor Fragments). - Breaking: Removed
destinationTypein favor of the new interface. - Breaking: Removed support for
@RendererDestination.
0.18.0 (2023-10-19)¶
Navigation¶
- New:
com.freeletics.khonshu.deeplinksGradle plugin that generates AndroidManifestintent-filtersbased on definitions from atomlfile - New: The navigation-testing artifact now ships with
DeepLinkDefinitions.containsAllDeepLinks(Set<DeepLinkHandler>)which checks that the deep links defined in thetomlare match the given set ofDeepLinkHandlers. - Breaking: All deep link related classes have been moved to the
com.freeletics.khonshu.navigation.deeplinkspackage.
0.17.0 (2023-09-25)¶
Navigation¶
com.freeletics.khonshu:navigationis now a multiplatform module with JVM and Android targets. The goal is not to support multiplatform navigation (for now at least), but to make it possible to referenceNavRoutein Kotlin/JVM modules.
Codegen¶
- Breaking: Renamed the Compose
@ComposeDestnationannotation to@NavDestinationand the Fragment@ComposeDestinationto@ComposeFragmentDestination. - Breaking: Removed
@ScopeToand@ForScopeannotations. They have been replaced by Anvil’s@SingleInand@ForScopefromcom.squareup.anvil:annotations-optional. - New: The code generation now supports KSP. The functionality is generally the same
- New: A new
@NavHostActivityannotation was added and will generate anActivityand the related boilerplate. Check out the docs for more details. - It’s now possible to use both
@NavDestinationand@ComposeFragmentDestinationat the same time on the same composable. This allows transitioning from Fragments to Compose more easily. - Removed:
@RendererScreenand@ComposeScreenannotations. These allowed generating Fragments and Composables without relying on Khonshu navigation. We’ve only ever used this for Activities which now have a better solution. In the beginning we saw the codegen and navigation as 2 separate things but now the codegen is more of an add-on, so we decided to remove the standalone mode (codegen without navigation) for codegen. - The following 3 artifacts are now empty and will not be published anymore from the next release
onwards. They have been merged into
com.freeletics.khonshu:codegen-runtimeand depend on it to make updating easier.com.freeletics.khonshu:codegen-scopecom.freeletics.khonshu:codegen-composecom.freeletics.khonshu:codegen-fragment
com.freeletics.khonshu:codegen-runtimeis now a multiplatform module with JVM and Android targets. The code generation still only supports Android but a few classes likeAppScopecan now be referenced from Kotlin/JVM modules.
0.16.1 (2023-08-07)¶
Navigation¶
- Added
awaitNavigatemethod toNavigatorTurbinethat takes a lambda as parameter. It verifies that one nav event, containing all navigation actions from the lambda, is being received.
0.16.0 (2023-08-01)¶
- Now uses Kotlin 1.9.0 and Anvil 2.4.7.
Navigation¶
- Added
navigatemethod toNavEventNavigatorthat takes a lambda as parameter. That lambda can contain multiple navigation actions that will end up being bundled into one event that
Codegen¶
- Added general
ForScopeannotation. - It’s now possible to use the
scopeof another screen using codegen asparentScope. - The above replace the need to
@NavEntryComponentand@NavEntrywhich have both been removed. - To enable the parent scope mechanism the following the 3 types now need a
ForScopequalifier:NavEventNavigatorSavedStateHandle- anything provided into the
SetofCloseables
0.15.0 (2023-07-11)¶
MAD has beed renamed to Khonshu and Whetstone is now just codegen.
| Old | New |
|---|---|
com.freeletics.mad:navigator-runtime |
com.freeletics.khonshu:navigation |
com.freeletics.mad:navigator-compose |
com.freeletics.khonshu:navigation-compose |
com.freeletics.mad:navigator-experimental |
com.freeletics.khonshu:navigation-experimental |
com.freeletics.mad:navigator-fragment |
com.freeletics.khonshu:navigation-fragment |
com.freeletics.mad:navigator-testing |
com.freeletics.khonshu:navigation-testing |
com.freeletics.mad:whetstone-compiler |
com.freeletics.khonshu:codegen-compiler |
com.freeletics.mad:whetstone-scope |
com.freeletics.khonshu:codegen-scope |
com.freeletics.mad:whetstone-runtime |
com.freeletics.khonshu:codegen-runtime |
com.freeletics.mad:whetstone-runtime-compose |
com.freeletics.khonshu:codegen-compose |
com.freeletics.mad:whetstone-runtime-fragment |
com.freeletics.khonshu:codegen-fragment |
com.freeletics.mad:whetstone-navigation |
Merged into com.freeletics.khonshu:codegen-runtime |
com.freeletics.mad:whetstone-navigation-compose |
Merged into com.freeletics.khonshu:codegen-compose |
com.freeletics.mad:whetstone-navigation-fragment |
Merged into com.freeletics.khonshu:codegen-fragment |
com.freeletics.mad:state-machine |
com.freeletics.khonshu:state-machine |
com.freeletics.mad:state-machine-testing |
com.freeletics.khonshu:state-machine-testing |
com.freeletics.mad:text-resource |
com.freeletics.khonshu:text-resource |
Navigation¶
- Compose: The
DialogandBottomSheetdestination types haven been replaced by a newOverlaydestination. This new type generally behaves like the old ones except for not automically wrapping the given content in aDialogorModalBottomSheetLayoutcomposable. This gives more flexibility and avoids some issues in the default implementations, like not being able to show multiple bottom sheet destinations on top of each other. It is recommended to use something like Material 3’sModalBottomSheetto display a bottom sheet. - Compose: Removed dependency on Accompanist and usages of experimental APIs.
Codegen¶
- Updated
DestinationTypefor the navigation change above. - Renamed
DestinationComponenttoNavDestinationComponent.
0.14.1 (2023-05-26)¶
Whetstone¶
- Generated composables now you remember when retrieving objects from a component to avoid creating new instances on each recomposition.
0.14.0 (2023-05-10)¶
Navigator¶
- Removed
saveCurrentRootStatefromnavigate(NavRoot, ...)method. - Added
resetToRoot(NavRoot)as a replacement. - Added
com.freeletics.mad:navigator-experimentalwhich is an experimental alternative implementation ofnavigator-composewithout a dependency on AndroidX navigation. The artifact is source and binary compatible withnavigator-composeso it can be easily tested by added the following tosettings.gradle:gradle.beforeProject { configurations.configureEach { resolutionStrategy.eachDependency { if (requested.group == "com.freeletics.mad" && requested.name == "navigator-compose") { useTarget("com.freeletics.mad:navigator-experimental:${requested.version}") } } } }
StateMachine¶
- Added support for all tier 1, 2 and 3 Kotlin/Native targets
0.13.3 (2023-03-24)¶
Whetstone¶
- Fix calls
asComposeState()leading to a crash.
0.13.2 (2023-03-23)¶
Whetstone¶
- Fix
whetstone-scopeartifact being published asaarinstead of asjar.
0.13.1 (2023-03-23)¶
- Updated to Compose 1.4.0 and Accompanist 0.30.0.
StateMachine¶
- Added
tvosSimulatorArm64andwatchosX64targets.
0.13.0 (2023-03-14)¶
Navigator¶
- Added proguard rules to not obfuscate the names of
NavRoute,NavRootandActivityRoutesubclasses.
Whetstone¶
- The
stateandsendActionparameters in annotated composables are now optional and only need to be specified if they are needed - The
stateandsendActionparameters of annotated composables can now have different names - Automatically discover
ViewRenderer.Factorysubclass nested inside the annotatedViewRendererand removed the now obsoleterendererFactoryparameter
0.12.0 (2023-02-13)¶
Navigator¶
- Added docs for deep link support.
- Internal changes and refactorings.
Whetstone¶
- BREAKING simplified integration with the navigator library
- removed the
@NavDestinationannotation - added
@ComposeDestinationand@RendererDestinationas replacements - these new annotations also replace
@ComposeScreen/@ComposeFragment/@RendererFragmentso that always just one Whetstone annotation is needed per screen routeandscopeare combined into arouteparameter which removes the need to define scope classes, theNavRouteorNavRootserves both purposes- the previous point means that the same
routewill also need to be used in any place that that requires scope markers like@ScopeTo,@ContributesToor@ContributesBinding - New
AppScopescope marker class. This can be used as the scope marker for an app level component. All whetstone annotations use it as default value forparentScopeanddestinationScope, so those two don’t need to be explicitly specified anymore after adopintAppScope. - Fixed compiler warning produced by generated code.
- Generated Fragments for compose now use
DisposeOnViewTreeLifecycleDestroyed.
StateMachine¶
- added Kotlin/JS as target
0.11.0 (2023-02-06)¶
Navigator¶
- new
navigator-testingartifact to testNavEventNavigator, see docs NavEventand other APIs that were marked as visible for testing are now marked as internal- compose navigation APIs are not annotated with
ExperimentalMaterialNavigationApianymore
StateMachine¶
- new
state-machine-testingartifact, see docs
Whetstone¶
- support for Anvil 2.4.4
- injecting into
Composablefunctions now supports generic types - added docs for
Closeablesupport which allows cleaning up resources - Internal: clean up and streamline code in the code generator
0.10.1 (2023-01-13)¶
Navigator¶
- fix crash when
DeepLinkcontains anActivityRoute
0.10.0 (2023-01-10)¶
Navigator¶
- added support for handling deep links, see
DeepLinkandDeepLinkHandler(more docs coming soon) navigateToRootnow has asaveCurrentRootStateparameter which defaults to true (matches the previous implicit behavior). Can be set to false to clear the current back stack.navigateBackTonow does not allow passing aNavRootas target anymore. UsenavigateToRoot<...>(false, false)insteadActivityRouteis now alwaysParcelableand has been split into 2 sub-classes/interfacesInternalActivityRouteforActivityclasses inside the app andExternalActivityRoutefor Intents that leave the appPermissionResultis now a sealed class instead of an enum class. TheDENIEDandDENIED_FOREVERvalues were merged into a singleDeniedsubclass that has ashowRationaleboolean property. This beingfalsewould match the old denied forever value. The reason for this change is thatDeniedwithshowRationalebeingfalsedoes not necessarily mean denied forever on newer platform versions, it could also mean that the first ever permission prompt was dismissed without making a choice.- Make a few APIs that were not meant to be public internal or mark them as such
- Internal: share more code between the compose and fragment implementations
- Internal: unify handling of permission results and activity results
Whetstone¶
- Remove dependency on AndroidX navigation. Whetstone’s navigation artifacts now only rely on our own navigator APIs
- Internal: Stop generating view models for each annotated screen. Instead use a runtime class to hold on to components
0.9.1 (2022-11-23)¶
Whetstone¶
- Fix action lambda in Compose code generation
0.9.0 (2022-11-22)¶
Whetstone¶
- Add support for injecting dependencies into Composable functions, which are annotated with
@ComposeScreenor@ComposeFragment
Navigator¶
- Refactor runtime module to remove androidx navigation
0.8.1 (2022-11-08)¶
Whetstone¶
- Update codegen to use new
Bundle.requireRoutefunction
Other¶
- New module for shared androidx navigation
- Deploy docs directly from Github Actions
0.8.0 (2022-11-08)¶
Navigator¶
- Add
Activity.getRoute()function than returns nullableActivityRoute - Use
requireNotNullcontracts forrequireRoutefunctions - Check for route to be not null before adding it to
IntentinCustomActivityNavigator - Move generated
DestinationComponentto the nav entry generator. This reduces how often we generate the contributedDestinationComponentby generating it only together with theNavEntryComponentthat needs it.
Whetstone¶
- Rename
findDependenciestofindComponentByScope. After getting rid of component dependencies in favor of subcomponents our find methods were not named correctly anymore. - Fix
Closeabletypo - Remove unused
SavedStateRegistryOwner - Explicitly require a renderer factory to extend
ViewRenderer.Factory. We relied on some custom factories internally. Those are not necessary anymore and we can add the constraint to the annotation.
Dependencies¶
- Update
kotlinto v1.7.20 - Update dependency
app.cash.turbine:turbineto v0.12.1 - Update dependency
androidx.fragment:fragmentto v1.5.4 - Update dependency
com.google.accompanist:accompanist-navigation-materialto v0.27.0 - Update
androidx-compose-runtimeto v1.3.0 - Update
androidx-navigationto v2.5.3 - Update
androidx-activityto v1.6.1 - Update dependency
org.jetbrains.kotlinx.binary-compatibility-validatorto v0.12.1 - Update dependency
com.android.libraryto v7.3.1 - Update dependency
org.jetbrains.dokkato v1.7.20 - Update dependency
com.google.dagger:daggerto v2.44 - Update dependency
androidx.core:coreto v1.9.0 - Update dependency
com.vanniktech.maven.publishto v0.22.0 - Update
androidx-navigationto v2.5.2 - Update actions/setup-java action to v3
- Update actions/setup-python action to v4
- Update actions/checkout action to v3
- Update dependency
com.autonomousapps.dependency-analysisto v1.13.1 - Update
anvilto v2.4.2
Other¶
- Migrate to Gradle version catalog
0.7.2 (2022-08-12)¶
Navigator¶
- Fragment: Fix that the start destination sometimes does not have any arguments
- Fix an issue that caused navigation results to be delivered multiple times
0.7.1 (2022-07-12)¶
- Sources are now visible in Android Studio again
Navigator¶
- Fix a crash in the navigation result APIs
0.7.0 (2022-07-04)¶
Updated to Kotlin 1.7.0 and Compose compiler 1.2.0.
Whetstone¶
- Instead of generating full components Whetstone is now using subcomponents with Anvil’s
@ContributesSubcomponentwith aParentComponentinterface that is automatically contributed to theparentScope. This allows to removekaptfrom modules using Whetstone and let Anvil do all of the factory generation - Because of that the
dependenciesparameter was removed from all annotations - To avoid collisions between subcomponents the
SavedStateHandleas well as theNavRouteorBundlethat are automatically available in generated@NavEntryComponents now have aNavEntry(ScopeOfNavEntryComponent::class)qualifier on them - The
rxJavaEnabledandcoroutinesEnabledparameters were removed from all annotations. For how to replace them, see the 0.5.0 changelog.
Navigator¶
- removed dependency on
LiveData
0.6.0 (2022-06-28)¶
Whetstone¶
- For components generated through
@NavEntryComponentthe automatically providedSavedStateHandle,NavRoute,Set<Closeable>,CoroutineScopeandCompositeDisposableobjects now use@NavEntry(Scope::class)as qualifier
0.5.0 (2022-06-21)¶
Navigator¶
- fix an issue where an
ActivityRoutethat is alsoParcelablewould not be added to theIntentextras
Whetstone¶
- It is now possible to provide
Closeableobjects into a set and have the generatedViewModelclose all of these when it is cleared. This is meant as a replacement for therxJavaEnabledandcoroutinesEnabledflags. You can replace the flags with the following snippet:
@ContributesTo(MyScreenScope::class)
object {
@Provides
@ScopeTo(MyScreenScope::class)
fun provideCompositeDisposable() = CompositeDisposable()
@Provides
@IntoSet
fun bindCompositeDisposable(disposable: CompositeDisposable) = Closeable { disposable.clear() }
@Provides
@ScopeTo(MyScreenScope::class)
fun provideCoroutineScope() = MainScope()
@Provides
@IntoSet
fun bindCoroutineScope(scope: CoroutineScope) = Closeable { scope.cancel() }
}
- removed
enableInsetHandlingparameter from@ComposeFragment, Compose 1.2.0 provides new inset APIs that work out of the box without any special integration and the Accompanist Inset library was deprecated
0.4.0 (2022-06-13)¶
Navigator¶
- New
ActivityRouteinterface that has to be used forActivitydestinations. This allows creating afillInIntentwith parameters to the routes which will be merged with the destinationIntent. Before this it was not possible to dynamically add values to theIntent. See the README - New
Activity.requireRouteextension function that allows obtaining theActivityRoutethat was used to navigate to thisActivity. NavHostnow has adestinationChangedCallbackparameter to receive destination changes for debugging purposesNavHostnow has parameters to change the styling of its bottom sheet
Whetstone¶
- Added README with documentation
- Fix code generation in Kotlin 1.6.20
0.3.1 (2022-04-20)¶
Whetstone¶
- fix a crash when
@NavEntryComponentis completely unused - fix a crash when using Whetstone with Compose navigation
0.3.0 (2022-04-13)¶
Navigator¶
A new library that is a wrapper around AndroidX navigation that allows to separate navigation logic from the UI layer and provides a scalable approach to type safe navigation in a highly modularized code base. For more information check out it’s README.
implementation 'com.freeletics.mad:navigator:0.3.0'
// when using composables for navigation
implementation 'com.freeletics.mad:navigator-compose:0.3.0'
// when using fragments for navigation (even if these contain composables)
implementation 'com.freeletics.mad:navigator-fragment:0.3.0'
Whetstone¶
Experimental release of an Anvil plugin that generates components and more for a screen. The experimental status only means that this will have breaking changes in the future and functionality might change significantly and that the documentation is missing (other than comments on the code). It is already being used in production at Freeletics.
0.2.0 (2021-06-18)¶
- update
StateMachine.stateto returnStateFlow<State>instead ofFlow<State>
0.1.1 (2021-06-16)¶
- fix windows artifact of
state-machinenot being published
0.1.0 (2021-06-16)¶
- initial release of the
state-machineartifact - initial release of the
text-resourceartifact