compose-multiplatform-patterns

Provide Compose Multiplatform UI patterns for state, navigation, and theming.

Updated Jul 27, 2026
One-click install
npx skills add https://github.com/kouiso/designdiff --skill compose-multiplatform-patterns-kouiso
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: compose-multiplatform-patterns
Source: https://github.com/kouiso/designdiff/tree/main/.claude/skills/compose-multiplatform-patterns
Command: npx skills add https://github.com/kouiso/designdiff --skill compose-multiplatform-patterns-kouiso

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

This Skill provides best practices and patterns for building user interfaces with Compose Multiplatform and Jetpack Compose, ensuring consistency, maintainability, and performance across different platforms.

Core Features & Use Cases

  • State Management: Demonstrates ViewModel integration with Compose state using StateFlow and the Event Sink pattern.
  • Navigation: Illustrates type-safe navigation with @Serializable routes and dialog/bottom sheet patterns.
  • Composable Design: Offers guidance on slot-based APIs and correct modifier ordering.
  • Platform-Specific UI: Shows how to handle platform differences using expect/actual.
  • Performance Optimization: Covers stable types, key(), derivedStateOf, and avoiding allocations.
  • Theming: Includes an example of Material 3 dynamic theming.

Quick Start

Activate this skill to get guidance on implementing state management in a Compose Multiplatform application.

Frequently Asked Questions about compose-multiplatform-patterns

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

FAQPage Schema
How do I manage state in Compose Multiplatform with Kotlin Multiplatform?

Handle platform-specific UI differences in Kotlin Multiplatform using the expect/actual mechanism to define shared declarations and provide platform-specific implementations for iOS and Android.

What is the best way to implement type-safe navigation in Compose Multiplatform?

Optimize Compose Multiplatform performance by using stable types, key(), derivedStateOf, and avoiding unnecessary allocations to minimize recomposition across shared UI components.

How do I handle platform-specific UI differences in Kotlin Multiplatform?

Handle platform-specific UI differences in Kotlin Multiplatform using the expect/actual mechanism to define shared declarations and provide platform-specific implementations for iOS and Android.

What is the best way to implement type-safe navigation in Compose Multiplatform?

Implement type-safe navigation in Compose Multiplatform by using @Serializable routes alongside dedicated dialog and bottom sheet patterns to structure your shared UI flow.

How do I optimize Compose Multiplatform performance and avoid unnecessary recompositions?

Optimize Compose Multiplatform performance by using stable types, key(), derivedStateOf, and avoiding unnecessary allocations to minimize recomposition across shared UI components.

Can I use Material 3 dynamic theming in a Kotlin Multiplatform shared UI?

Yes, you can apply Material 3 dynamic theming in Kotlin Multiplatform shared UIs to maintain visual consistency across iOS and Android platforms.