LazyGridPrefetchStrategy
Function
Common
@ExperimentalFoundationApi
fun LazyGridPrefetchStrategy(nestedPrefetchItemCount: Int = 2): LazyGridPrefetchStrategy
Creates an instance of the default LazyGridPrefetchStrategy
, allowing for customization of the
nested prefetch count.
Parameters
nestedPrefetchItemCount | specifies how many inner items should be prefetched when this LazyGrid is nested inside another LazyLayout. For example, if this is the state for a horizontal LazyGrid nested in a vertical LazyGrid, you might want to set this to the number of items that will be visible when this grid is scrolled into view. If automatic nested prefetch is enabled, this value will be used as the initial count and the strategy will adapt the count automatically. |