Skip to content

Arkitekt

An Android and Kotlin Multiplatform architecture library built on Jetpack Compose and Kotlin Coroutines.

Arkitekt is a testable foundation for Android and KMP apps. It offers two architecture paths that share the same core principles:

  • Android / Compose: ViewModel + Hilt + Jetpack Compose
  • Decompose / KMP: BaseComponent + Koin + Kotlin Multiplatform

Key features

  • Compose-ready ViewModels with built-in state management and one-shot events
  • Coroutine use cases for testable business logic (UseCase and FlowUseCase)
  • Kotlin Multiplatform support via Decompose with Koin dependency injection
  • A KSP factory generator for Decompose components (@GenerateFactory)
  • kotlin.Result integration with getOrCancel for safe coroutine error handling
  • Testing utilities for mocking use cases, testing ViewModels, and testing Decompose components

Quick installation

dependencies {
    // Android / Compose
    implementation("app.futured.arkitekt:core:6.1.0")
    implementation("app.futured.arkitekt:cr-usecases:6.1.0")
    implementation("app.futured.arkitekt:compose:6.1.0")

    // Decompose / KMP (optional)
    implementation("app.futured.arkitekt:decompose:6.1.0")
    implementation("app.futured.arkitekt:decompose-annotation:6.1.0")
    ksp("app.futured.arkitekt:decompose-processor:6.1.0")
}

See Installation for full details and snapshot builds.


Get started

Android / Compose

Set up a Jetpack Compose project with ViewModel, ViewState, and Hilt.

Project Setup Quick Start

Decompose / KMP

Set up a Kotlin Multiplatform project with BaseComponent, Koin, and Decompose.

Project Setup Quick Start


Sample projects

The sample projects below use the same patterns as this documentation.

Android / Compose

The example module in this repository contains a minimal Android sample. For a complete project setup, see the Android Project Template.

Decompose / KMP

The KMP Futured Template is a full Kotlin Multiplatform project (Android + iOS) using BaseComponent, Koin, Decompose navigation, and KSP factory generation.