TakaOtaku / Digimon-Card-App

Website to keep track of your Digimon Card Collection and Build Decks with it.
MIT License
28 stars 16 forks source link

Firefox performance problem #483

Closed lupoDharkael closed 8 months ago

lupoDharkael commented 1 year ago

When I opened #481 it felt like the input processing was really bad so I thought the real cause was the card filtering computation. But after the fix it didn't feel like the situation improved. Even worse, the performance problem was also affecting other text fields such as the Deck name or the deck description text fields but I only focused on the card search problem because it had a way worse performance problem. After investigating a little I found the app works as intended in Chrome and the performance problem is only present in Firefox.

image

Here is the performance results of 3 key presses in the "Deck name" text field. image There is a non trivial 300ms delay after every key press before the event is completely processed. It is not a hardware problem as I use a Ryzen 7 2700X and the app also works great in Chrome. I'm using Mozilla Firefox version 112.0.

As it can be seen in the first image most of the time is spent updating nested components as methods like refreshView, refreshComponent, refreshEmbeddedViews and refreshChildComponents are seen constantly in the stack trace. I may try to look at it more but webdev is not my field of expertise.

TakaOtaku commented 1 year ago

That is great information to know! I am in the process of reworking some older code to work reactive which should improve performance. With that I hope this will be fixed :)

lupoDharkael commented 8 months ago

Can confirm the last update actually made the search experience way better in Firefox. I'm going to close the issue as it seems to be fixed!