[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"project-7415":3},{"id":4,"name":5,"fullName":6,"owner":7,"repo":5,"description":8,"homepage":9,"htmlUrl":10,"language":11,"languages":10,"totalLinesOfCode":10,"stars":12,"forks":13,"watchers":14,"openIssues":15,"contributorsCount":16,"subscribersCount":16,"size":16,"stars1d":16,"stars7d":17,"stars30d":18,"stars90d":16,"forks30d":16,"starsTrendScore":19,"compositeScore":20,"rankGlobal":10,"rankLanguage":10,"license":21,"archived":22,"fork":22,"defaultBranch":23,"hasWiki":22,"hasPages":24,"topics":25,"createdAt":10,"pushedAt":10,"updatedAt":31,"readmeContent":32,"aiSummary":33,"trendingCount":16,"starSnapshotCount":16,"syncStatus":34,"lastSyncTime":35,"discoverSource":36},7415,"Decompose","arkivanov\u002FDecompose","arkivanov","Kotlin Multiplatform lifecycle-aware business logic components (aka BLoCs) with routing (navigation) and pluggable UI (Jetpack Compose, SwiftUI, JS React, etc.)","https:\u002F\u002Farkivanov.github.io\u002FDecompose",null,"Kotlin",2835,105,23,3,0,6,25,1,63.58,"Apache License 2.0",false,"master",true,[26,27,28,29,30],"android","kotlin","kotlin-multiplatform","multiplatform","navigation","2026-06-12 04:00:33","\u003Cpicture>\n  \u003Csource media=\"(prefers-color-scheme: light)\" srcset=\"https:\u002F\u002Fraw.githubusercontent.com\u002Farkivanov\u002FDecompose\u002Fmaster\u002Fdocs\u002Fmedia\u002Flogo\u002Ftitled-1.png\">\n  \u003Csource media=\"(prefers-color-scheme: dark)\" srcset=\"https:\u002F\u002Fraw.githubusercontent.com\u002Farkivanov\u002FDecompose\u002Fmaster\u002Fdocs\u002Fmedia\u002Flogo\u002Flogo-titled-dark.png\">\n  \u003Cimg src=\"https:\u002F\u002Fraw.githubusercontent.com\u002Farkivanov\u002FDecompose\u002Fmaster\u002Fdocs\u002Fmedia\u002Flogo\u002Ftitled-1.png\" width=\"300\">\n\u003C\u002Fpicture>\n\n\u003Cbr\u002F>\n\u003Cbr\u002F>\n\n[![License](https:\u002F\u002Fimg.shields.io\u002Fbadge\u002FLicense-Apache%202.0-blue.svg)](http:\u002F\u002Fwww.apache.org\u002Flicenses\u002FLICENSE-2.0)\n[![Twitter URL](https:\u002F\u002Fimg.shields.io\u002Fbadge\u002FTwitter-@arkann1985-blue.svg?style=social&logo=twitter)](https:\u002F\u002Ftwitter.com\u002Farkann1985)\n\n---\n\nDecompose is a Kotlin Multiplatform library for breaking down your code into tree-structured lifecycle-aware business logic components (aka BLoC), with routing functionality and pluggable UI (Jetpack\u002FMultiplatform Compose, Android Views, SwiftUI, Kotlin\u002FReact, etc.).\n\nPlease see the [project website](https:\u002F\u002Farkivanov.github.io\u002FDecompose\u002F) for documentation and APIs. \n\nShould you have any questions or ideas - there is [Discussions](https:\u002F\u002Fgithub.com\u002Farkivanov\u002FDecompose\u002Fdiscussions) section. Also welcome to the Kotlin Slack channel - [#decompose](https:\u002F\u002Fkotlinlang.slack.com\u002Farchives\u002FC03H3N51SKT)! You can also try using [DeepWiki](https:\u002F\u002Fdeepwiki.com\u002Farkivanov\u002FDecompose)!\n\n## Why Decompose?\n\n* Decompose breaks the code down into small and independent components and organizes them into trees. Each parent component is only aware of its immediate children.\n* Decompose draws clear boundaries between UI and non-UI code, which gives the following benefits:\n  * Better separation of concerns\n  * Pluggable platform-specific UI (Compose, SwiftUI, Kotlin\u002FReact, etc.)\n  * Business logic code is testable with pure multiplatform unit tests\n* Navigation state is fully exposed - plug any UI you want, animate as you like using your favourite UI framework's API or use predefined API.\n* Navigation is a pure function from the old state to a new one - navigate without limits.\n* Proper dependency injection (DI) and inversion of control (IoC) via constructor, including but not limited to type-safe arguments.\n* Shared navigation logic\n* Lifecycle-aware components\n* Components in the back stack are not destroyed, they continue working in background without UI\n* State preservation (automatically on Android, manually on all other targets via `kotlinx-serialization`)\n* Instances retaining (aka ViewModels) over configuration changes (mostly useful in Android)\n\n### Meme time!\n\n\u003Cimg src=\"docs\u002Fmedia\u002FDecomposeMeme.png\" width=\"512\">\n\n## Setup\n\nPlease check the [Installation](https:\u002F\u002Farkivanov.github.io\u002FDecompose\u002Fgetting-started\u002Finstallation\u002F) section of the documentation.\n\n### Supported platforms\n\nIn general, Decompose supports the following targets: `android`, `jvm`, `ios`, `watchos`, `tvos`, `macos`, `wasmJs`, `js`. However, some modules do not support all targets or the support depends on the Decompose version. Please see the installation docs for details.\n\n## Overview\n\nHere are some key concepts of the library, more details can be found in the documentation.\n\n* [Component](https:\u002F\u002Farkivanov.github.io\u002FDecompose\u002Fcomponent\u002Foverview\u002F) - every component represents a piece of logic with its own lifecycle, the UI is optional and is plugged externally\n* [ComponentContext](https:\u002F\u002Farkivanov.github.io\u002FDecompose\u002Fcomponent\u002Foverview\u002F#componentcontext) - every component has its own [ComponentContext], which makes components lifecycle-aware and allows state preservation, instances retaining (aka AndroidX `ViewModel`) and back button handling\n* [Child Stack](https:\u002F\u002Farkivanov.github.io\u002FDecompose\u002Fnavigation\u002Fstack\u002Foverview\u002F) - enables navigation between child components, nested navigation is also supported\n* [Child Slot](https:\u002F\u002Farkivanov.github.io\u002FDecompose\u002Fnavigation\u002Fslot\u002Foverview\u002F) - allows only one child component at a time, or none\n* [Child Pages](https:\u002F\u002Farkivanov.github.io\u002FDecompose\u002Fnavigation\u002Fpages\u002Foverview\u002F) - a list of child components with one selected component (e.g. pager-like navigation)\n* [Child Panels](https:\u002F\u002Farkivanov.github.io\u002FDecompose\u002Fnavigation\u002Fpanels\u002Foverview\u002F) - a multi-pane navigation \n* [Generic Navigation](https:\u002F\u002Farkivanov.github.io\u002FDecompose\u002Fnavigation\u002Fchildren\u002Foverview\u002F) - provides a way to create your own custom navigation model, when none of the predefined models fit your needs\n* [Lifecycle](https:\u002F\u002Farkivanov.github.io\u002FDecompose\u002Fcomponent\u002Flifecycle\u002F) - provides a way to listen for lifecycle events in components\n* [StateKeeper](https:\u002F\u002Farkivanov.github.io\u002FDecompose\u002Fcomponent\u002Fstate-preservation\u002F) - makes it possible to preserve state or data in a component when it gets destroyed\n* [InstanceKeeper](https:\u002F\u002Farkivanov.github.io\u002FDecompose\u002Fcomponent\u002Finstance-retaining\u002F) - retains instances in your components (similar to AndroidX `ViewModel`)\n* [BackPressedHandler](https:\u002F\u002Farkivanov.github.io\u002FDecompose\u002Fcomponent\u002Fback-button\u002F) - provides a way to handle and intercept back button presses\n\n### Decompose is a library\n\nDecompose is a library that can be used as a framework. In its core, Decompose just manipulates instances of `ComponentContext` with strict parent-child relationship, which is also called \"navigation\". The possibility of creating custom implementations of the `ComponentContext` interface allows adding custom properties and functions, as well as storing additional data in each instance of `ComponentContext`. This makes it a very powerful tool with various use cases.\n\nThe \"component\" term is just one of the possible usages, the recommended one. The [Decompose-Router](https:\u002F\u002Fgithub.com\u002Fxxfast\u002FDecompose-Router) library is a great example of leveraging Decompose to create a custom navigation solution with a completely different API.\n\n### Component hierarchy\n\n\u003Cimg src=\"docs\u002Fmedia\u002FComponentHierarchy.png\" width=\"512\">\n\n### Pluggable UI hierarchy\n\n\u003Cimg src=\"docs\u002Fmedia\u002FPluggableUiHierarchy.png\" width=\"512\">\n\n### Typical component structure\n\n\u003Cimg src=\"docs\u002Fmedia\u002FComponentStructure.png\" width=\"512\">\n\n## Quick start\n\nPlease refer to the [Quick start](https:\u002F\u002Farkivanov.github.io\u002FDecompose\u002Fgetting-started\u002Fquick-start\u002F) section of the docs.\n\n## Samples\n\nCheck out the [Samples](https:\u002F\u002Farkivanov.github.io\u002FDecompose\u002Fsamples\u002F) section of the docs for a full description of each sample.\n\n## Template\n\nCheck out the [template repository](https:\u002F\u002Fgithub.com\u002Farkivanov\u002Fdecompose-multiplatform-template) which may be used to kick-start a project for you.\n\n## \"Used by\" list\n\nCheckout a voluntary list of projects\u002Fcompanies using Decompose: https:\u002F\u002Fgithub.com\u002Farkivanov\u002FDecompose\u002Fdiscussions\u002F366. Feel free to add your project!\n\n## Articles\n\n- [Decompose — experiments with Kotlin Multiplatform lifecycle-aware components and navigation](https:\u002F\u002Fproandroiddev.com\u002Fdecompose-experiments-with-kotlin-multiplatform-lifecycle-aware-components-and-navigation-a04ef3c7f6a3?source=friends_link&sk=f7d289cc329b6c8a765fc049e36c313f)\n- [Fully cross-platform Kotlin applications (almost)](https:\u002F\u002Fproandroiddev.com\u002Ffully-cross-platform-kotlin-applications-almost-29c7054f8f28?source=friends_link&sk=4619fdcb17912fde589bc4fca83efbbd)\n- [A comprehensive thirty-line navigation for Jetpack\u002FMultiplatform Compose](https:\u002F\u002Fmedium.com\u002Fp\u002F5b723c4f256e) - if you find Decompose verbose and would prefer something built on top of Compose.\n\n- \"Component-based Approach\" series by [Artur Artikov](https:\u002F\u002Ftwitter.com\u002Fartik_artikov)\n  - Part 1: [Fighting Complexity in Android Applications](https:\u002F\u002Fmedium.com\u002F@a.artikov\u002Fcomponent-based-approach-fighting-complexity-in-android-applications-2eaf5e8c5fad)\n  - Part 2: [Implementing Screens with the Decompose Library](https:\u002F\u002Fmedium.com\u002F@a.artikov\u002Fcomponent-based-approach-implementing-screens-with-the-decompose-library-19c41d8ed087)\n\n## Author\n\nTwitter: [@arkann1985](https:\u002F\u002Ftwitter.com\u002Farkann1985)\n\nIf you like this project you can always \u003Ca href=\"https:\u002F\u002Fwww.buymeacoffee.com\u002Farkivanov\" target=\"_blank\">\u003Cimg src=\"https:\u002F\u002Fcdn.buymeacoffee.com\u002Fbuttons\u002Fv2\u002Fdefault-blue.png\" alt=\"Buy Me A Coffee\" height=32>\u003C\u002Fa> ;-)\n","Decompose是一个Kotlin多平台库，用于将代码分解为树结构的生命周期感知业务逻辑组件（即BLoC），并支持路由功能和可插拔UI（如Jetpack Compose、SwiftUI、JS React等）。其核心功能包括清晰划分UI与非UI代码界限、提供完全暴露的导航状态以实现自定义动画及过渡效果、支持依赖注入和控制反转。此外，Decompose还保证了组件在后台继续运行且状态得以保存，非常适合需要跨平台开发同时保持良好代码组织的应用场景，尤其是在Android、iOS以及其他支持的平台上构建复杂导航逻辑和用户界面时。",2,"2026-06-11 03:12:11","top_language"]