add

fun add(data: String, type: String): DataTransferItem?(source)

The DataTransferItemList.add() method creates a new DataTransferItem using the specified data and adds it to the drag data list.

MDN Reference