Update index.js

Javascript to drag and drop