Open gustaveWPM opened 2 months ago
The browser cache should be caching the relevant indexes/fragments, and if I do the same action as described I'm not seeing any significant delay — and the index chunks are served from my browser cache.
There is one request in the flow which is explicitly uncached, which is the request for the entry JSON file. (see https://pagefind.app/pagefind/pagefind-entry.json )
This file will never be cached, as the contents are used to cache-bust the rest of the requests. If you're on a slower connection then pulling this file might cause the small delay, but that's the only thing I can think of that would affect a refresh.
The browser cache should be caching the relevant indexes/fragments, and if I do the same action as described I'm not seeing any significant delay — and the index chunks are served from my browser cache.
There is one request in the flow which is explicitly uncached, which is the request for the entry JSON file. (see https://pagefind.app/pagefind/pagefind-entry.json )
This file will never be cached, as the contents are used to cache-bust the rest of the requests. If you're on a slower connection then pulling this file might cause the small delay, but that's the only thing I can think of that would affect a refresh.
Interesting! I'll try with someone who has a better connection and computer than me.
Indeed, this is caused by my poor hardware and connection. Sorry, I should have checked it before writing this issue.
No worries! It's still good to hear from people that the experience can be slow, I'll keep that in mind :)
No worries! It's still good to hear from people that the experience can be slow, I'll keep that in mind :)
I'm exaggerating when I say it's slow. There's just a perceptible delay in my reaction time, but I don't have to wait more than a second either.
It's only on the first request, so maybe it's due to some computations more than connection.
Oh... Finally, it looks like this is slower on Firefox than on Chrome. I'm curious.
Hmm — my primary browser is Firefox and I've never noticed an issue.
OS / Firefox version?
Hmm — my primary browser is Firefox and I've never noticed an issue.
OS / Firefox version?
Ubuntu 22.04.4 LTS x86_64 Kernel: 6.5.0-27-generic CPU: Intel i3-10110U (4) @ 4.100GHz GPU: Intel CometLake-U GT2 [UHD Graphics] Memory: 7674MiB
Firefox 125.0
Everything is faster on Chromium on this setup.
Hello there!
I noticed that the first search is always slower than the others.
For example: https://pagefind.app/
If I search
hello
, I will have a little delay ("Searching for hello..."). Then, if I searchhello
again, the search will be really fast.But if I refresh the page, then start again to search
hello
, I will have the little delay again.Is it planned to populate the browser cache (like requests caching) to improve this?