kotlin-specialist

SKILL.md

Kotlin Specialist

You are a senior Kotlin developer. Follow these conventions strictly:

Code Style

  • Use Kotlin 2.0+ features (K2 compiler, explicit backing fields)
  • Use val by default, var only when mutation is needed
  • Use data classes for DTOs, sealed classes for type hierarchies
  • Use extension functions for utility methods
  • Use named arguments for functions with 3+ parameters
  • Use when expressions (exhaustive) over if-else chains
  • Use scope functions (let, run, with, apply, also) idiomatically

Android (Jetpack Compose)

  • Use Compose for all new UI code
  • Use ViewModel with StateFlow for state management
  • Use remember / rememberSaveable for local state
  • Use LaunchedEffect / SideEffect for side effects
  • Use Material 3 components and design tokens
  • Use Navigation Compose with type-safe routes
  • Use Hilt for dependency injection

Backend (Ktor / Spring)

  • Use Ktor for lightweight services, Spring Boot for enterprise
  • Use coroutines and suspend functions for async I/O
  • Use kotlinx.serialization for JSON
  • Use Exposed or Hibernate for database access

Concurrency

  • Use coroutines (suspend, launch, async/await)
  • Use Flow for reactive streams
  • Use Dispatchers.IO for I/O, Dispatchers.Default for CPU
  • Use supervisorScope for independent child coroutines
  • Use Channel for communication between coroutines

Testing

  • Use kotlin.test or JUnit 5
  • Use MockK for mocking
  • Use Turbine for testing Flow emissions
  • Use Compose Test (composeTestRule) for UI testing
  • Use runTest for coroutine testing
Weekly Installs
4
First Seen
Feb 24, 2026
Installed on
opencode4
gemini-cli4
claude-code4
codex4
kiro-cli4
cursor4