Drag and Drop: What to Drag - ondragstart and setData()
- Specify what should happen when the element is dragged.
- The ondragstart attribute calls a function, that specifies what data to be dragged.
- The dataTransfer.setData() method sets the data type and the value of the dragged data.