dj-fiorex / angular2-smart-table

Angular 2 Smart Data Table component
https://dj-fiorex.github.io/angular2-smart-table/
MIT License
54 stars 20 forks source link

Mouse Move Event is triggering Change Detection #145

Open uap-universe opened 8 months ago

uap-universe commented 8 months ago

When the column resize function was implemented, some mouse listeners were registered to detect the click and drag events for the column separator.

Unfortunately, what nobody noticed, that mouse listeners are causing high frequent change detection runs when you just move your mouse over the area of the table.

This has high performance impact and is most likely one of the reasons why notebooks start their rocket engines when opening a page containing a smart table.

uap-universe commented 8 months ago

I did some research, but "the internet says" that this behavior from the HostListener is by design.

That means, probably, the whole thing would need a major overhaul to be fixed.

The unfortunate thing about it is, that the user is paying the costs even when column resizing is completely deactivated.