1.0.5 • Published 6 years ago

js-draggable v1.0.5

Weekly downloads
1
License
MIT
Repository
github
Last release
6 years ago

Simple JS Draggable

Example

window.addEventListener('DOMContentLoaded', function() {
  var el = document.querySelector('#elem');

  var draggable = new Draggable(el);

  draggable
    .on('dragstart', function() { console.log('dragstart', this); })
    .on('dragend', function() { console.log('dragend', this); })
    .on('move', function() { console.log('move', this.diffX, this.diffY); });
});

Credits

Based on TZDragg by thezillion

1.0.5

6 years ago

1.0.4

6 years ago

1.0.3

6 years ago

1.0.2

6 years ago

1.0.1

6 years ago

1.0.0

8 years ago