Kotlin Articles

Android Architecture Evolution: From MVC Confusion to MVI in Compose

A practical walkthrough of Android architecture patterns from MVC and MVP to MVVM and MVI, with Compose-focused guidance for unidirectional data flow.

Android Modular Communication: Route Tables and SPI Service Discovery

A practical comparison of two Android modular communication strategies: route tables and interface extraction with SPI service discovery, including implementation details and selection guidance.

Jetpack Compose Modifier Internals: From Modifier.Node to Layout and Drawing

A deep dive into the Compose Modifier chain, the shift from composed to Modifier.Node, how declarative modifier pipelines are built, and where performance gains come from.

Testing Kotlin Coroutines: TestDispatcher, Virtual Time, and Turbine

A practical guide to coroutine unit testing with runTest virtual time, TestDispatcher injection, Dispatchers.Main replacement, Turbine Flow assertions, and common Android testing traps.

Compose Custom Layout: MeasurePolicy, Intrinsics, and Waterfall Layouts

A deep dive into Jetpack Compose custom layout, from MeasurePolicy constraints and intrinsic measurement to SubcomposeLayout, adaptive grids, waterfall layouts, and debugging tips.

Inside Android Room: KSP Code Generation, Migrations, and Flow Queries

Walk through Room's KSP-generated DAO code, migration strategy, and Flow reactive queries, from compile-time SQL validation to InvalidationTracker.

Jetpack Compose Animation Internals: AnimationSpec, Springs, and Transition

A deep dive into Compose animation internals, including spring physics, the Choreographer-to-Snapshot frame pipeline, and how Transition synchronizes multiple animated properties.

Inside Android ViewModel: ViewModelStore Retention and SavedStateHandle Recovery

Trace ViewModel from ViewModelStore retention to SavedStateHandle process recreation, and separate configuration-change survival from process-death recovery.

Compose Recomposition: Strong Skipping, Compiler Reports, and State Reads

(Updated on )
A practical end-to-end guide to diagnosing and optimizing Compose recomposition, covering stability inference, compiler reports, Layout Inspector, derivedStateOf, and state read placement.

Android Gradle Build Speed: From Configuration Cache to Replacing KAPT with KSP

A systematic Android Gradle build-speed guide covering configuration time, annotation processing, task execution, Configuration Cache, KSP migration, incremental compilation, and build governance.

Android Paging 3 Deep Dive: PagingSource, RemoteMediator, and Reactive Pagination

A deep breakdown of Paging 3's three-layer architecture: Pager, PagingSource, and RemoteMediator, including Room, RecyclerView, coroutine dispatchers, caching, and common pitfalls.

Kotlin Flow Engineering: Cold Flows, Channels, StateFlow, and SharedFlow

A practical guide to Kotlin Flow's cold and hot stream models, Channel primitives, SharedFlow and StateFlow tradeoffs, and Android MVVM layer choices.

Kotlin K2 Compiler: Unified Frontend, Type Inference, and Android Migration

A practical deep dive into Kotlin K2's FIR frontend, rewritten type inference, build-performance impact, kapt-to-KSP migration, compiler plugin changes, and Android project rollout.

Kotlin `suspend` Internals: From CPS Transformation to State-Machine Bytecode

A compiler-level walkthrough of how Kotlin turns suspend functions into state-machine bytecode, from CPS transformation and Continuation to local-variable liveness and coroutine resumption.

Jetpack Compose Snapshot State: From MutableState to Recomposition

A deep dive into Compose Snapshot as an MVCC runtime, covering MutableState writes, Snapshot apply, RecomposeScope invalidation, derivedStateOf, and MutationPolicy.

Android ConnectivityManager Deep Dive: From NetworkCallback to Adaptive Network Switching

From NetworkInfo's limits to the NetworkCapabilities model, this article explains real-time network monitoring and adaptive switching with ConnectivityManager.

Kotlin Inline Functions and reified: Bytecode-Level Optimization

A bytecode-level look at Kotlin inline functions, noinline, crossinline, and reified generics, with practical notes for Compose and compiler optimization.

Kotlin Value Classes and Inline Classes: Zero-Overhead Type Safety

A deep dive into Kotlin inline class and value class compilation, boxing elimination, JVM signatures, Android performance patterns, and serialization compatibility.

Kotlin Symbol Processing: KSP from Annotation Scanning to Code Generation

A full walkthrough of KSP as a KAPT replacement, from SymbolProcessor and Resolver to CodeGenerator, incremental builds, multiplatform support, and migration.

Kotlin Sealed Classes and Interfaces: Type-Safe UI State

A practical guide to Kotlin sealed classes and sealed interfaces, from exhaustive when checks to type-safe Compose UI state, MVI reducers, Flow results, and Navigation routes.