What problem does it solve?
This Skill guides AmethystMultiplatform Kotlin developers to implement robust architecture patterns, including StateFlow/SharedFlow state management, sealed hierarchies, immutability, and DSL builders, with practical, code-backed guidance.
Core Features & Use Cases
- StateFlow and SharedFlow patterns for UI state and event streams in multi-platform apps
- Sealed Classes and Sealed Interfaces for modeling state variants and generic results
- @Immutable and data class practices to improve Compose performance and immutability
- DSL Builders for type-safe fluent APIs and readable configuration
- Inline/reified techniques for zero-overhead abstractions and runtime type access
Quick Start
Refactor a sample Kotlin project to implement a StateFlow-based AccountManager and a SharedFlow-based RelayConnectionManager, following the patterns described above.