Opened 2 years ago

Last modified 3 weeks ago

#15097 new bug

Sortable in 1.12.x much (min 3x) slower than 1.11.x

Reported by: cucko Owned by:
Priority: minor Milestone: none
Component: ui.sortable Version: 1.12.1
Keywords: Cc:
Blocked by: Blocking:

Description

Here are two js fiddle examples

jq ui 1.11.4: https://jsfiddle.net/5z7fw7Lb/1/

jq ui 1.12.0: https://jsfiddle.net/5z7fw7Lb/

jq ui 1.12.1: https://jsfiddle.net/5z7fw7Lb/2/

Change History (4)

comment:1 Changed 2 years ago by Daijobou

I can confirm this problem. I have a page with six lists and summary ~3000 items. Chrome crashes with this browser tab, but only with version jquery ui 1.12.1. Sortable in version jquery ui 1.11.4 working fast and fine as replacement.

Other source: http://stackoverflow.com/a/41624770/706420

comment:2 Changed 19 months ago by Stephane

I can confirm the issue as well

comment:3 Changed 18 months ago by syddiqua

Same problem. Anyone will fix it after a year?.. 900 elements take 55sec, with 1.11.4 it takes only a few.

comment:4 Changed 3 weeks ago by naitsirch

Same problem here. I have a small snippet to reproduce the issue:

<ul></ul>

<script src="https://code.jquery.com/jquery-3.3.1.min.js"></script>
<script src="https://code.jquery.com/ui/1.12.1/jquery-ui.min.js"></script>
<script>
  var ul = jQuery('ul');
  
  for(var i = 0; i < 2000; i++) {
    ul.append(jQuery('<li>List item ' + i + '</li>'));
  }

  ul.sortable({axis: 'y'});
</script>

I have found out that it is stuck when it assigns the class 'ui-sortable-handle' to the list's items (_setHandleClassName function).

The adding of the class takes longer for each item that has been processed.

Last edited 3 weeks ago by Ryan J Ollos (previous) (diff)
Note: See TracTickets for help on using tickets.