LazyColumn
Interactively explore Jetpack Compose's LazyColumn properties and generate code.
Properties
Preview
Item #1
Item #2
Item #3
Item #4
Item #5
Item #6
Item #7
Item #8
Item #9
Item #10
Item #11
Item #12
Item #13
Item #14
Item #15
Item #16
Item #17
Item #18
Item #19
Item #20
Generated Code
import androidx.compose.foundation.layout.*
import androidx.compose.foundation.lazy.LazyColumn
import androidx.compose.foundation.lazy.items
import androidx.compose.material3.Text
import androidx.compose.runtime.Composable
import androidx.compose.ui.Alignment
import androidx.compose.ui.Modifier
import androidx.compose.ui.unit.dp
@Composable
fun MyLazyColumn() {
LazyColumn(
modifier = Modifier.fillMaxSize(),
contentPadding = PaddingValues(
top = 8.dp,
bottom = 8.dp,
start = 0.dp,
end = 0.dp
),
reverseLayout = false,
verticalArrangement = Arrangement.spacedBy(8.dp),
horizontalAlignment = Alignment.Start,
userScrollEnabled = true
) {
items(20) { index ->
Text(
text = "Item #$index",
modifier = Modifier
.fillMaxWidth()
.padding(16.dp)
)
}
}
}