compose-multiplatform

compose-multiplatform is a skill for Claude Code, Codex from ericrisco/rsc-harness. It costs 80 tokens per session (2,776 once invoked), scanned A, original, MIT.

A guide for building one shared Kotlin user interface that runs on Android, iOS, and desktop with Compose Multiplatform. Platform-specific code is used only where the operating systems require it.

In plain words
What is it for?
Use it for shared UI in commonMain, platform-specific integrations with expect/actual, and multiplatform view models, navigation, or dependency injection.
Why use it?
It helps keep the interface consistent across platforms while handling differences in navigation, native APIs, and platform setup explicitly.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Use it for shared UI in commonMain, platform-specific integrations with expect/actual, and multiplatform view models, navigation, or dependency injection.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/ericrisco/rsc-harness/compose-multiplatform
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add ericrisco/rsc-harness --skill compose-multiplatform
Clone the repo
git clone --depth 1 https://github.com/ericrisco/rsc-harness

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for compose-multiplatform

README.md
[![agentmods](https://agentmods.dev/badge/skills/ericrisco/rsc-harness/compose-multiplatform/github.svg)](https://agentmods.dev/skills/ericrisco/rsc-harness/compose-multiplatform)
Your own site
<a href="https://agentmods.dev/skills/ericrisco/rsc-harness/compose-multiplatform"><img src="https://agentmods.dev/badge/skills/ericrisco/rsc-harness/compose-multiplatform/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for compose-multiplatform

Your own site · 80×15
<a href="https://agentmods.dev/skills/ericrisco/rsc-harness/compose-multiplatform"><img src="https://agentmods.dev/badge/skills/ericrisco/rsc-harness/compose-multiplatform.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 80 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 2,776 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00080 $0.02776
Opus 5.5 $0.00032 $0.01110
Sonnet 5.5 $0.00016 $0.00555
Haiku 4.5 $0.00008 $0.00278

Measured 1mo ago against content hash d801b9003297, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

compose-multiplatform scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 1mo ago.

The scan reads SKILL.md. This mod also ships 1 executable file (scripts/verify.sh), listed below but not scanned — reading those needs a real analyzer, not pattern matching.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

skills/compose-multiplatform/SKILL.md · 199 lines

How it starts

The opening of the file, as written. The whole thing — 199 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Compose Multiplatform

You write one Compose UI tree in commonMain and let each platform be a thin host. The whole discipline is one sentence: common by default, platform by exception. Every line you put in commonMain ships to Android, iOS, and desktop unchanged; every line you put in a platform source set is a deliberate exception you should be able to justify.

Versions floor (2026)

Pin these or the K2 compiler bites you. Verify against current docs before locking a project — these are the floors, not opinions.

  • Compose Multiplatform 1.11.0, bundling Jetpack Compose 1.11.1.
  • Kotlin 2.1.0+ required (2.2.20 recommended for evolving iOS/Web targets). Since CMP 1.8.0 the K2 compiler is mandatory, so every dependency must compile against Kotlin 2.1.0+.
  • iOS is Stable (production-ready since CMP 1.8.0, May 2025): feature parity for popular cases, type-safe navigation with deep linking, accessibility (VoiceOver, Full Keyboard Access).
  • Web is Beta (CMP 1.9.0, Sept 2025), runs on WasmGC browsers. Do not promise Web parity — ship Android/iOS/desktop, pilot Web.
  • Platform minimums: Android API 21, iOS 14+, macOS 13 arm64, Windows 10+, Ubuntu 20.04+, desktop JDK 11+ (17+ for jpackage packaging).

Where does this code go?

This is the question you answer dozens of times a day. Default to the leftmost column that compiles.

Source set Put here Concrete example Never here
commonMain Shared @Composables, ViewModels, business logic, common interfaces, expect declarations @Composable fun GreetingScreen(), expect fun platformName(): String android.*, platform.UIKit, java.awt, androidx.activity
androidMain Activity, actual using Android Context/Build class MainActivity : ComponentActivity iOS/desktop-only APIs
iosMain ComposeUIViewController factory, actual via cinterop/platform.* fun MainViewController() = ComposeUIViewController { App() } android.*
desktopMain application {} window, Swing interop application { Window(::exitApplication) { App() } } mobile-only APIs
wasmJsMain (Beta) Web entry point ComposeViewport(document.body!!) { App() } anything you can't ship as Beta

Read the full file on GitHub · 199 lines

Files

What ships with it

5 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 1mo ago First seen · 199 lines · 80 tokens per session scan A d801b9003297

Subscribe to this mod's changes

compose-multiplatform is a skill published in the GitHub repository ericrisco/rsc-harness (231 stars, last pushed yesterday), licensed MIT. It adds 80 tokens to every session and 2,776 once invoked, about $0.0003 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other skills, from other repositories

mapkit

MapKit + CoreLocation for iOS (iOS 17–26 era). SwiftUI Map with MapContentBuilder (Marker / Annotation / MapPolyline / MapPolygon / MapCircle / UserAnnotation), MapCameraPosition & MapCamera with onMapCameraChange, mapStyle / mapControls / selection, MapReader + MapProxy coordinate conversion, and Look Around…

TalissonVitorino/kmp-ios-skills · 246 tokens

navigation

Navigation for Android and Kotlin Multiplatform/iOS apps - all three approaches in one place. (A) Jetpack Navigation Compose (androidx.navigation - NavController, NavHost, composable , type-safe @Serializable routes, nested graphs, bottom nav, deep links, results via SavedStateHandle). (B) Jetpack Navigation 3 / Nav3…

TalissonVitorino/kmp-ios-skills · 177 tokens

kmp-repositories

Repository pattern for Kotlin Multiplatform. Shared interfaces with platform-specific implementations, clean data layer architecture.

TalissonVitorino/kmp-ios-skills · 25 tokens

shared-coroutines

Coroutines and Flow in Kotlin Multiplatform shared code - expect/actual dispatchers, iOS main-thread/Darwin constraints, a CoroutineScope shared from commonMain, and exposing StateFlow/Flow to Swift (KMP-NativeCoroutines/SKIE). Use for commonMain/iosMain concurrency. For general, non-multiplatform coroutine and Flow…

TalissonVitorino/kmp-ios-skills · 115 tokens

kmp-networking

Ktor HTTP client for Kotlin Multiplatform - shared API layer in commonMain with per-target engines (OkHttp/Android engine on Android, Darwin on iOS), kotlinx.serialization, and shared error handling. Use for multiplatform or shared networking. For an Android-only Ktor/OkHttp client use ktor-patterns. For deeper…

TalissonVitorino/kmp-ios-skills · 105 tokens

shared-models

Shared data models for Kotlin Multiplatform using kotlinx.serialization. Cross-platform domain models with validation and serialization.

TalissonVitorino/kmp-ios-skills · 25 tokens