Skip to content

$dragOut

the method is called when an item is moved out of a possible drop landing during dnd

function $dragOut(
// a DOM element from which a drag-n-drop action has started
source: HTMLElement,
// a DOM element of the drop from which an item has been moved out
old_target: HTMLElement,
// a new DOM element which will be used as a drop target (can be "null")
new_target: HTMLElement,
// a native HTML event
ev: Event
): void

You can override it with your own logic, but check drag-n-drop related events first, as they provide a much more convenient way for drag-n-drop handling.

Articles