<div class='sourceset sourceset-common'>Common</div>

```kotlin
object ScrollableDefaults
```

Contains the default values used by [scrollable](/jetpack-compose/androidx.compose.foundation/foundation/modifiers/scrollable)

## Functions

```kotlin
@Composable fun flingBehavior(): FlingBehavior
```

Create and remember default [FlingBehavior](/jetpack-compose/androidx.compose.foundation/foundation/interfaces/FlingBehavior) that will represent natural fling curve.

<h2 id="overscrolleffect">overscrollEffect</h2>

```kotlin
@Composable
    fun overscrollEffect(): OverscrollEffect
```

Returns a remembered [OverscrollEffect](/jetpack-compose/androidx.compose.foundation/foundation/interfaces/OverscrollEffect) created from the current value of
[LocalOverscrollFactory](/jetpack-compose/androidx.compose.foundation/foundation/properties/LocalOverscrollFactory).

This API has been deprecated, and replaced with [rememberOverscrollEffect](/jetpack-compose/androidx.compose.foundation/foundation/composable-functions/rememberOverscrollEffect)

<hr class="docs-overload-divider">

<h2 id="reversedirection-layoutdirection-orientation-reversescrolling">reverseDirection</h2>

```kotlin
fun reverseDirection(
        layoutDirection: LayoutDirection,
        orientation: Orientation,
        reverseScrolling: Boolean,
    ): Boolean
```

Calculates the final `reverseDirection` value for a scrollable component.

This is a helper function used by [androidx.compose.foundation.scrollableArea](/jetpack-compose/androidx.compose.foundation/foundation/modifiers/scrollableArea) to determine
whether to reverse the direction of scroll input. The goal is to provide a "natural"
scrolling experience where content moves with the user's gesture, while also accounting for
the [layoutDirection](/jetpack-compose/androidx.compose.ui/ui-test/functions/LayoutDirection).

The logic is as follows:
1. To achieve "natural" scrolling (content moves with the gesture), scroll deltas are  inverted. This function returns `true` by default when `reverseScrolling` is `false`.
2. In a Right-to-Left (`Rtl`) context with a `Horizontal` orientation, the direction is  flipped an additional time to maintain the natural feel, as the content is laid out from  right to left.

#### Parameters

| | |
| --- | --- |
| layoutDirection | current layout direction (e.g. from [LocalLayoutDirection](/jetpack-compose/androidx.compose.ui/ui/properties/LocalLayoutDirection)) |
| orientation | orientation of scroll |
| reverseScrolling | whether scrolling direction should be reversed |

#### Returns

| | |
| --- | --- |
|  | `true` if scroll direction should be reversed, `false` otherwise. |