getodk / getodk/central

Cache hover card responses

Open
#1,266 0 comments 1 reaction 0 assignees View on GitHub
frontend performance
Dominant language
JavaScript
Stars
226
Forks
235
Avg merge
2d 22h
Merged PRs (30d)
19

Description

From https://github.com/getodk/central-frontend/pull/1067#pullrequestreview-2490335054:

> What do you think of caching the response of hover requests until user navigates to another page/route? right now every time I hover on a link a request is sent.

I think this is a good idea. It's very possible that the user will hover over one resource, then move somewhere else, then return to hovering over the resource.

One thought I had is that we should consider putting a limit on the size of this cache. If the user has hovered over a bunch of resources on a single large page, we might not want to keep them all in memory. Maybe just the last 10 or 20 that the user has hovered over.

Contributor guide

No contributing guide indexed for this repository

Research direction

Start by locating the frontend hover-card request handling and the route-navigation lifecycle. Trace how hover responses are fetched, then verify that repeated hovers reuse responses, navigation clears the cache, and the cache remains bounded to a small number of resources.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript
Domain
frontend
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.