When starting to drag an element using HTML5 draggable attribute, original element is still visible, so I end up having two elements visible instead of one.
How can I do to have only the element being dragged visible (the original one should be momentarily hidden).
<script>
function startDrag() {
// hide initial element
}
function endDrag() {
// reset initial element
}
</script>
<div class=draggable draggable=true
ondragstart=startDrag(event)
ondragend=endDrag(event)
></div>
Here's a jsfiddle to show the problem https://jsfiddle.net/gjc5p4qp/