---
title: "draggedItemIDs(for:)"
framework: swiftui
role: symbol
role_heading: Instance Method
path: "swiftui/dropsession/localsession-swift.struct/draggeditemids(for:)"
---

# draggedItemIDs(for:)

Provides an array of identifiers of the currently dragged items if available.

## Declaration

```swift
func draggedItemIDs<ItemID>(for type: ItemID.Type) -> [ItemID] where ItemID : Hashable
```

## Discussion

Discussion If drag started within the application, the dragged items have identifiers, and SwiftUI has access to these identifiers, you can access them using this method. Parameter type: The type of the identifiers. Returns: The array with the identifiers of the dragged items if provided. Returns an empty array if there are no dragged identifiers of a given type.
