Currently, logos are being fetched from the server every time they are rendered. Go through and impliment caching to make a standard way of storing logos locally. For example, when switching between the points and PDF when viewing a match, the logos should not be fetched every time.
Note that while you're doing this, you should look for other instances of this with, for example, the match data itself or the PDF. Logos are the most visible but we want to eventually optimize all of these as well.
Tips
I did a refactor for keeping track of match state and using the context api with a custom hook useMatchData. You could follow a similar pattern, and either couple the logos to this state or do a new state or osmethign different altogether.
Currently, logos are being fetched from the server every time they are rendered. Go through and impliment caching to make a standard way of storing logos locally. For example, when switching between the points and PDF when viewing a match, the logos should not be fetched every time.
Note that while you're doing this, you should look for other instances of this with, for example, the match data itself or the PDF. Logos are the most visible but we want to eventually optimize all of these as well.
Tips
I did a refactor for keeping track of match state and using the context api with a custom hook
useMatchData
. You could follow a similar pattern, and either couple the logos to this state or do a new state or osmethign different altogether.