mainsail-crew / mainsail

Mainsail is the popular web interface for managing and controlling 3D printers with Klipper.
https://docs.mainsail.xyz
GNU General Public License v3.0
1.71k stars 363 forks source link

perf: fix hang when leaving G-Code Preview page #1949

Closed nathanregner closed 3 months ago

nathanregner commented 3 months ago

Description

This PR fixes a performance issue when leaving the G-Code Preview page.

To reproduce:

Related Tickets & Documents

For whatever reason, my Firefox started choking on this recently. Chrome at least recovered so I could get a profile :smiley:

Before

before

After

after

Mobile & Desktop Screenshots/Recordings

[optional] Are there any post-deployment tasks we need to perform?

meteyou commented 3 months ago

Thank you very much for this performance fix!