# DropTarget (@salmonui/data-grid/engine)

> The DropTarget interface of @salmonui/data-grid/engine.

Canonical: https://salmonui.dev/docs/reference/data-grid/engine/DropTarget

```ts
import type { DropTarget } from '@salmonui/data-grid/engine';
```

Also exported from `@salmonui/data-grid/engine/row-drag-drop`.

Entry index: https://salmonui.dev/docs/reference/data-grid/engine (Markdown with every symbol of the entry: https://salmonui.dev/docs/reference/data-grid/engine.md).

## Reference

Kind: interface

```ts
interface DropTarget extends DropPoint {
    readonly dropIndex: number;
    readonly valid: boolean;
    readonly reason: string | null;
}
```

Members (9):

| Name | Signature | Flags | Description |
| --- | --- | --- | --- |
| `dropIndex` | `readonly dropIndex: number;` |  | The data row index the first dropped row takes after the drop (`reorderRows(fromIndexes, dropIndex)` semantics); -1 when unknown (a collapsed group's rows). |
| `valid` | `readonly valid: boolean;` |  |  |
| `reason` | `readonly reason: string \| null;` |  | `self`, `sorted`, `groupChange`, `lazyGroups`, `emptyGroup`, or null. |
| `index` | `index: number;` | inherited | Visible index (clamped); `count` when the model is empty. |
| `rowId` | `rowId: string \| null;` | inherited | Id of the row under the pointer, or null for an empty model. |
| `kind` | `kind: RowKind;` | inherited |  |
| `position` | `position: DropPosition;` | inherited |  |
| `groupId` | `groupId: string \| null;` | inherited | Group (caption row id) the drop lands in, or null when ungrouped. |
| `parentId` | `parentId?: string \| null;` | optional, inherited | Tree mode: the parent the dropped rows join (null: roots); absent outside tree mode. |
