https://kotlinlang.org logo
#glance
Title
k

Kimon

10/13/2022, 2:37 PM
Is there a limit of 10 children inside a
Column
or
Row
in Glance? I get a
java.lang.IllegalArgumentException: Cannot find container Row with 11 children
error once I try to add the 11th children.. 🤔
b

bbade_

10/13/2022, 6:05 PM
There is. Because glance renders to remoteviews under the hood, it has to use statically generated layouts. The row/column layouts it uses have a maximum of 10 child slots. You can try using a lazy collection, or if you don't mind nesting you can wrap layouts.
k

Kimon

10/13/2022, 7:16 PM
Thank you for the answer. Unfortunately there is no
LazyRow
so I guess I'll have to group them in groups of 10.
19 Views