marceljuenemann / angular-drag-and-drop-lists

Angular directives for sorting nested lists using the HTML5 Drag & Drop API
MIT License
2.16k stars 713 forks source link

Massive performance hit when any `ng` attributes inside the draggable item #464

Open chorsnell opened 6 years ago

chorsnell commented 6 years ago

Hi @marceljuenemann, first up thanks for your hard work on the repo!

For a while we've noticed an issue with a draggable whose items contains ng attributes, eg not simple {{vars}}.

This has 300 items and is super fast / snappy https://codepen.io/jcjmcclean/pen/xXeKKj

This has 300 items, each containing an <input ng-model=""> and its almost unusable as far as dragging performance goes. https://codepen.io/anon/pen/LeaXrP

With less items, its less of an issue, but it seems to degrade with more complex use of ng attributes inside each item. We have a list with perhaps 10 items, but various directives / interactive elements, and its just not usable.

Any ideas / fixes / suggestions welcome :)

andyschr commented 6 years ago

Same issue here. Did you find a workaround?

chorsnell commented 6 years ago

@andyschr no :( we ended up using https://github.com/a5hik/ng-sortable instead