---
title: "rememberSnapFlingBehavior"
description: "Create and remember a FlingBehavior for decayed snapping in Lazy Lists. This will snap the item
according to [snapPosition]."
type: "composable"
---

<div class='type'>Composable Function</div>


<a id='references'></a>

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


```kotlin
@Composable
fun rememberSnapFlingBehavior(
    lazyListState: LazyListState,
    snapPosition: SnapPosition = SnapPosition.Center,
): FlingBehavior
```


Create and remember a FlingBehavior for decayed snapping in Lazy Lists. This will snap the item
according to `snapPosition`.

#### Parameters

| | |
| --- | --- |
| lazyListState | The `LazyListState` from the LazyList where this `FlingBehavior` will be used. |
| snapPosition | The desired positioning of the snapped item within the main layout. This position should be considered with regards to the start edge of the item and the placement within the viewport. |




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


```kotlin
@Composable
fun rememberSnapFlingBehavior(
    snapLayoutInfoProvider: SnapLayoutInfoProvider
): TargetedFlingBehavior
```


Creates and remember a `FlingBehavior` that performs snapping.

#### Parameters

| | |
| --- | --- |
| snapLayoutInfoProvider | The information about the layout that will do snapping |




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


```kotlin
@Composable
fun rememberSnapFlingBehavior(
    lazyGridState: LazyGridState,
    snapPosition: SnapPosition = SnapPosition.Center,
): FlingBehavior
```


Create and remember a FlingBehavior for decayed snapping in Lazy Grids. This will snap the item
according to `snapPosition`.

#### Parameters

| | |
| --- | --- |
| lazyGridState | The `LazyGridState` from the LazyGrid where this `FlingBehavior` will be used. |
| snapPosition | The desired positioning of the snapped item within the main layout. This position should be considered with regards to the start edge of the item and the placement within the viewport. |





