HTML5 SORTABLE FOR ANGULARJS
I used sortable which provided by jqueryUI at this link, That's good but it's pretty heavy to use because not just sortable code is included, I just need sortable method, So I decided make sortable items by html5 instead, almost modern browsers support this.
Below is some reference links that help me get an overview before coding this directive.
- Native html5 sortable( jquery no longer required ).
- Support sortable which array is given ( pass by ngModel)
- You can choose specific handle element on item element.
- Offer callback when init directive or after item is dropped.
- Auto update sortable DOM when ngmodel is changed or removed sub item.
- Cross dropping
How to use
Include html5.sortable to your app
Define any varriable in scope with type is array
Define sortable options
Below is example in template code
If you don't want using option, you can edit to html-sortable="" in template.
Have fun !