Claude Skill MartBrowse skillsQuick linesLearn by videoTerminal guideWhat is a Skill?
← Back to list

Compose Multiplatform Platform Split Guide

Senior-level rules for Compose Multiplatform: what belongs in commonMain, when to use expect/actual vs interface + DI, and how to validate iOS, desktop and web targets.

Dev & CodingAdvanced★ 300⑂ 25AI score 9/10Last updated: Oct 2, 2026

What it does

  • Placement rules: ViewModels, Contracts and repository interfaces must live in commonMain; platform source sets only hold paths, bindings and translations.
  • Bridge decision table: stateful services (secure storage, players, auth, analytics) become commonMain interfaces bound in platform Koin modules; expect/actual is reserved for tiny stateless hooks.
  • iOS/Swift interop: SKIE as the default bridge, no hand-written Flow/suspend wrappers, and a small, concrete exported Swift surface.
  • Desktop & web pitfalls: missing kotlinx-coroutines-swing for Dispatchers.Main, per-platform DataStore paths, wasm limits.
  • Verification gates: check-commonmain-imports.sh blocks java.*, android.*, LocalContext and R from shared code and flags missing actuals.

Who it's for

  • Teams shipping Compose Multiplatform apps to Android, iOS, desktop and web
  • Developers tired of shared code that compiles on Android but breaks the iOS link
  • Leads who want Koin + SKIE conventions enforced like an automated code review

Examples

  1. "Add secure storage" → the skill routes it to a commonMain interface with androidMain/iosMain adapters bound via Koin, not expect/actual.
  2. "Consume this ViewModel Flow from Swift" → it points to SKIE setup and version checks in libs.versions.toml instead of a hand-rolled collector.
  3. "Desktop UI never updates" → it checks the Main dispatcher, multiplatform lifecycle artifacts and viewModelScope wiring.

· · · Install guide · · ·

Try it now, no install

Paste this into Claude to use the skill without installing anything.

Read the instructions in this file and follow them to help me:
https://raw.githubusercontent.com/Meet-Miyani/compose-skill/HEAD/skills/compose-platform/SKILL.md

What I want: (describe your task here)

If Claude can't open the link, open it yourself and paste the contents instead.

↓ If it works for you, download the ZIP below and install it. Then it runs on its own — no pasting each time.

Install in the Claude app (no terminal)
  1. Download the ZIP with the button below.
  2. In Claude, open Settings → Capabilities and turn on 'Code execution and file creation'. (one time)
  3. Go to Customize → Skills → + → 'Upload a skill' and upload the ZIP.
↓ Download ZIP
Install in Claude Code

Let Claude do it — paste this into Claude Code

Install the skill I found on Claude Skill Mart.
Copy the skills/compose-platform folder from the GitHub repo Meet-Miyani/compose-skill into my ~/.claude/skills/compose-platform/.
When it's done, tell me in one line what this skill can do.

Install with a command instead

git clone https://github.com/Meet-Miyani/compose-skill.git /tmp/compose-skill && mkdir -p ~/.claude/skills && cp -r /tmp/compose-skill/skills/* ~/.claude/skills/

⚠ This is a third-party skill. Check the source repository before installing.

  1. Open a terminal.
  2. Clone the repo: git clone https://github.com/Meet-Miyani/compose-skill.git
  3. Create the skills folder: mkdir -p ~/.claude/skills
  4. Copy the skills: cp -r compose-skill/skills/* ~/.claude/skills/ (copy all of them — this skill references sibling skills such as compose-architecture and compose-ui).
  5. Restart Claude Code, open your KMP project, and ask something like "review my commonMain placement" to trigger it.
  6. To use the verification script, make it executable: chmod +x ~/.claude/skills/compose-platform/scripts/run-checks.sh.