itemIf
fun LazyListScope.itemIf(condition: Boolean, key: Any? = null, contentType: Any? = null, content: @Composable LazyItemScope.() -> Unit)
Adds an item to a lazy list only when condition is true.
fun LazyGridScope.itemIf(condition: Boolean, key: Any? = null, contentType: Any? = null, span: LazyGridItemSpanScope.() -> GridItemSpan? = null, content: @Composable LazyGridItemScope.() -> Unit)
Adds an item to a lazy grid only when condition is true.