kotlin-multiplatform

Configure Kotlin Multiplatform source sets, targets, and expect/actual declarations.

Updated Jul 20, 2026
One-click install
npx skills add https://github.com/trancee/MeshLink-template --skill kotlin-multiplatform-trancee
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: kotlin-multiplatform
Source: https://github.com/trancee/MeshLink-template/tree/main/.agents/skills/kotlin-multiplatform
Command: npx skills add https://github.com/trancee/MeshLink-template --skill kotlin-multiplatform-trancee

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) and references (resource) components.

What problem does it solve?

This Skill simplifies the complexities of Kotlin Multiplatform (KMP) project management, including source set configuration, expect/actual declarations, and dependency management across multiple targets.

Core Features & Use Cases

  • Source Set Management: Easily add new targets and configure the source set hierarchy for Android, iOS, and JVM.
  • Expect/Actual Implementation: Provides standardized patterns for defining platform-specific abstractions and their implementations.
  • Dependency Orchestration: Simplifies adding shared or platform-specific libraries using version catalogs.
  • Use Case: When adding a new platform target like macOS or configuring a new KMP library dependency, this Skill provides the exact Gradle DSL and source set structure required to maintain project parity.

Quick Start

Use the kotlin-multiplatform skill to add a new iOS target and configure the necessary source sets for the project.

Frequently Asked Questions about kotlin-multiplatform

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I configure Kotlin Multiplatform source sets for Android, iOS, and JVM?

To configure Kotlin Multiplatform source sets, you define the target hierarchy and shared folders within your Gradle build script. This ensures shared business logic is correctly distributed across Android, iOS, and JVM platforms.

What is the best way to implement expect/actual declarations in a KMP project?

Implementing expect/actual declarations requires defining platform-specific abstractions in common source sets and providing their actual implementations in target-specific source sets. This pattern maintains consistent project architecture across platforms.

How do I add a new iOS target to an existing Kotlin Multiplatform project?

Adding an iOS target involves updating your Gradle DSL to include the new target and configuring the necessary source set hierarchy. This maintains project parity when expanding cross-platform Kotlin support.

Can I manage shared and platform-specific dependencies using Gradle version catalogs in KMP?

Yes, you can orchestrate shared and platform-specific dependencies using Gradle version catalogs. This simplifies dependency management by centralizing library versions and ensuring consistent integration across Kotlin Multiplatform targets.

Does Kotlin Multiplatform work for sharing business logic across mobile and JVM targets?

Kotlin Multiplatform works for sharing business logic across mobile and JVM targets by configuring a unified Gradle build script structure. It enables code parity for Android, iOS, and JVM applications without rewriting core logic.