---
title: "drop(_:toItemAt:)"
framework: uikit
role: symbol
role_heading: Instance Method
path: "uikit/uicollectionviewdropcoordinator/drop(_:toitemat:)"
---

# drop(_:toItemAt:)

Animates the item to the specified index path in the collection view.

## Declaration

```swift
func drop(_ dragItem: UIDragItem, toItemAt indexPath: IndexPath) -> any UIDragAnimating
```

## Parameters

- `dragItem`: The dragged item that you want to animate into position.
- `indexPath`: The index path to use as the destination for the animation.

## Mentioned in

Supporting Drag and Drop in Collection Views

## Discussion

Discussion Use this method to animate the dragged item to the specific location in the collection view. Typically, you use this method for content that originated in the collection view and is moving to a new location.

## See Also

### Animating Items to Their Destination

- [drop(_:intoItemAt:rect:)](uikit/uicollectionviewdropcoordinator/drop(_:intoitemat:rect:).md)
- [drop(_:to:)](uikit/uicollectionviewdropcoordinator/drop(_:to:)-7w5rn.md)
- [drop(_:to:)](uikit/uicollectionviewdropcoordinator/drop(_:to:)-l5tg.md)
