-
Notifications
You must be signed in to change notification settings - Fork 402
Using too many leader lines makes the browser laggy #141
Comments
Hi @AshutoshViramgama, thank you for the comment. |
Around 20 lines are drawn each time on drag |
There are 116 lines in https://anseki.github.io/leader-line/ . |
@anseki i got your point but they are not changing or redrawing lines on each event. I mean to say that on drag event on each mouse pointer changes each time 20 lines are removed and redrawn. for eg there are 20 lines at present on the page and if i change the mouse cursor on screen then at each mouse changing postion 20 lines are removed and redrawn again. did you got my point? |
Your report means that the code that removes and redraws lines has a bug. The example page that I indicated also has draggable lines. Therefore your code may have a bug. |
@anseki I'm facing same problem too with only 3 lines. I've 3 lines that are connected between 3 elements. when i keep dragging one of them, i have to re-draw/ call line.position() for all 3 lines. this causes laggy performance and a it's really noticeable. It'd be nice if you can provide several lines connected to one draggable item with a better performance. my example is line that:
|
hi @ahmedshaaban00 Anseki has 2 nice repositories that might help you. |
@christian-iron60, thank you for your help. 😄 @ahmedshaaban00, I also can't reproduce that problem. |
i meet same questions, please tell me how to fix。thanks |
i am using the database structure to create a web structure of connection between database and also all are drag-gable if there are 10 tables connected to each other all the connections are redrawn again on drag change and the lag is only happening in chrome browser.
The text was updated successfully, but these errors were encountered: