Huge performance hit when using the responsive extension

Huge performance hit when using the responsive extension

YoannYoann Posts: 3Questions: 1Answers: 0
edited October 2014 in Free community support

Hello,

I recently added the responsive extension to my application and noticed that the datatables initializations are way slower since then. I went from 80-200 ms to 2-3s in Firefox for a datatable with 380 entries, Chrome seems to be a little bit faster with a 2 seconds initialization and let's not even talk about Internet Explorer.

I also have a button that updates the datatable through an ajax call ( I have the "destroy" attribute set to true for that ) and I just noticed that the more I update my datatable, the longer it takes for it to be initialized. I go from 3 seconds for the first initialization to 18 seconds after 7 updates. It keeps taking longer even if the next initialization only has 30 entries to process.

All this happens only when I use the responsive extension so is this extension poorly optimized or am I missing something there ?

EDIT : I forgot to mention that I use Datatables 1.10.3 and Responsive 1.0.2

Thanks !

Replies

  • allanallan Posts: 61,726Questions: 1Answers: 10,109 Site admin

    Its not so much poorly optimised, and more part of how the software works unfortunately. It needs to take the size of the column, which is invariably a slow operation since the browser has to reflow the page. Specifically this part of the code.

    I'm not saying it can't be optimised! I'm not not sure how at this immediate moment how to do it. Ideas welcome!

    Allan

This discussion has been closed.