docs.rodeo

MDN Web Docs mirror

DragEvent

{{APIRef("HTML Drag and Drop API")}} 

The DragEvent interface is a DOM event that represents a drag and drop interaction. The user initiates a drag by placing a pointer device (such as a mouse) on the touch surface and then dragging the pointer to a new location (such as another DOM element). Applications are free to interpret a drag and drop interaction in an application-specific way.

This interface inherits properties from {{domxref("MouseEvent")}}  and {{domxref("Event")}} .

{{InheritanceDiagram}} 

Instance properties

Constructors

Although this interface has a constructor, it is not possible to create a useful DataTransfer object from script, since {{domxref("DataTransfer")}}  objects have a processing and security model that is coordinated by the browser during drag-and-drops.

Event types

Example

An Example of each property, constructor, event type and global event handlers is included in their respective reference page.

Specifications

{{Specifications}} 

Browser compatibility

{{Compat}} 

See also

In this article

View on MDN