react-dnd / react-dnd-html5-backend

HTML5 backend for React DnD [Legacy Repo]
MIT License
146 stars 97 forks source link

Dragging really slow because of HitTest. Disable hit testing on drag? #76

Open Cristy94 opened 6 years ago

Cristy94 commented 6 years ago

I have a complex element that is being dragged over a list of multiple other similar elements and only a single drop target. Sometimes dragging works fine, but sometimes it is very, very slow (like 1 frame per second).

Looking at the browser's performance tab I see that 50% of time is used doing HitTest when moving the dragged element around (which apparently is in the Rendering category even though it doesn't trigger paint flashing).

I think the issue that should be solved is the HitTest performance being so bad, but in my case I would only need to enable the HitTest on drop, not on move.

Can hit testing be disabled while dragging?

PS: I just assumed that HitTest is the HTML5 native drag-and-drop hit testing functionality, but I might be wrong.

Siocki commented 6 years ago

I have the same problem

pabeda-bt commented 6 years ago

+1