Async Image Preview Handler
@ExperimentalCoilApi
Convenience function that creates an AsyncImagePreviewHandler that returns an Image.
@ExperimentalCoilApi
Deprecated (with error)
Migrate to the AsyncImagePreviewHandler constructor that returns a not null Image. Alternatively, if you need to return a nullable Image, inline this code into your call site.
Replace with
import coil3.compose.AsyncImagePainter
Content copied to clipboard
AsyncImagePreviewHandler { _, request -> AsyncImagePainter.State.Loading(image(request)?.asPainter(request.context)) }Content copied to clipboard