Function

scrollToIndex

Action to scroll a container to the index of one of its items.

scrollToIndex

Source set: Common
public fun SemanticsPropertyReceiver.scrollToIndex(
    label: String? = null,
    action: (Int) -> Boolean,
): Unit

Action to scroll a container to the index of one of its items.

The action should throw an IllegalArgumentException if the index is out of bounds.

Jetpack Compose beyond MaterialFree components, screens and templates for apps that don’t look like Google’s. Copy them into your app, or let your coding agent add them.Browse for free

Content updated: