https://kotlinlang.org logo
Title
g

Glenn Martin

02/13/2021, 6:29 AM
everything here has a composable annotation so not sure what's the deal, your current sample projects still running on an older build, would be great if you could upgrade those so I can see the change
j

jim

02/13/2021, 4:36 PM
The trailing lambda parameter of
LazyRow
is of type
LazyListScope.() -> Unit
(notice that is NOT a composable lambda). If you look on the
LazyListScope
, you will see it provides an
item
function which does accept a
@Composable LazyItemScope.() -> Unit)
which IS composable.
g

Glenn Martin

02/14/2021, 1:36 PM
hi @jim thanks for the response, I got it working now. One question, do I need a lazy row inside a lazy column as I had in my previous impl? I have it working just with a Lazycolumn for the moment, I'm just displaying one item per row so not sure if I need a lazy row or when would I need one?
or would a lazyrow only be needed If I needed horizontal scrolling due to multiple number of rows per column?
j

jim

02/14/2021, 3:11 PM
The later, lazy widgets are only helpful if you have so much to display that it would be expensive to compose all of it at once.
g

Glenn Martin

02/20/2021, 2:16 AM
thanks mate