I think the title says it all.
LazyPagingItems
constructor is internal. I can't pass LazyPagingItems
as parameter in Preview Composable, let alone passing sample data. But I want to show preview of my composable, how should I do this?
@Composable
fun MainUi(users: LazyPagingItems<User>) {
Scaffold {
LazyColumn() {
items(users) {
// Rest of the code..
}
}
}
}
@Preview
@Composable
fun Preview() {
DefaultTheme {
MainUi(users = ) // How to pass sample data here?
}
}