function drag(event) { event.dataTransfer.setData('actual', event.target.id) } function drop(event) { const data = event.dataTransfer.getData('actual') event.target.appendChild(document.getElementById(data)) console.log(data) } function allowDrop(event) { event.preventDefault() }