What problem does it solve?
This Skill provides expert guidance on efficiently loading and displaying images within Jetpack Compose applications, addressing common challenges like performance, state management, and visual presentation.
Core Features & Use Cases
AsyncImage Composable: The primary tool for seamless image loading from URLs, supporting placeholders, error states, and transformations.
rememberAsyncImagePainter: For scenarios requiring direct Painter access or manual state observation.
SubcomposeAsyncImage: Enables custom slot APIs for different loading states (loading, success, error).
- Performance Optimization: Emphasizes singleton
ImageLoader, main-thread safety, crossfade transitions, and appropriate sizing.
- Use Case: Quickly implement an image gallery in your Compose app, ensuring smooth loading, placeholder display, and efficient memory usage.
Quick Start
Use the coil-compose skill to load an image from the URL 'https://example.com/image.jpg' into an AsyncImage composable with a crossfade effect.