1.0.4
🎉 Released a new version 1.0.4
! 🎉
What's New?
- Added RequiresOptIn for
ExperimentalCoroutinesApi
, so we don't need to addExperimentalCoroutinesApi
annotation anymore. - Now supports Coil for loading images.
implementation "com.github.skydoves:landscapist-coil:<version>"
We can request and load images simply using a CoilImage
composable function.
CoilImage(
imageModel = imageUrl,
// Crop, Fit, Inside, FillHeight, FillWidth, None
contentScale = ContentScale.Crop,
// shows a placeholder imageAsset when loading.
placeHolder = imageResource(R.drawable.placeholder),
// shows an error imageAsset when the request failed.
error = imageResource(R.drawable.error)
)
You can fully reference details here.