forge
Explore
Log in

Don't you dare go Hollow

🐛 stop Chromium dev-reload cache deadlock

Browse files at this commit

c19a9d5c55b93f03261c7928918326f98abceab1Ahmet Kaan GümüşParent: c41c4bc
  • fix
    • 🐛 stop Chromium dev-reload cache deadlock
Show full message
fix: 🐛 stop Chromium dev-reload cache deadlock

Chromium 150's HTTP cache wedges after a handful of reloads of a page that
fans out to ~230 separately-served, no-cache-revalidated dev modules
(kobalte/corvu ship unbundled): its cache entries lock and every later
request queues in the browser forever, so the tab never returns until a
fresh URL is opened in another tab. Serve dev responses no-store so the
browser never creates the entries. Dev-only; the production build is
served by nginx with its own cache headers.
vite.config.tsmodified+10 -0
@@ -12,6 +12,16 @@ export default defineConfig({
1212 },
1313 },
1414 server: {
15+ // Chromium 150's HTTP cache deadlocks when a page that fans out to ~230
16+ // separately-served, `no-cache`-revalidated dev modules (kobalte/corvu
17+ // ship unbundled) is reloaded a handful of times in a row: after ~7
18+ // reloads its cache entries wedge and every later request queues in the
19+ // browser forever — no bytes ever reach vite. `no-store` stops Chromium
20+ // from creating the cache entries at all. Dev-only; the production build
21+ // is served by nginx with its own cache headers.
22+ headers: {
23+ "Cache-Control": "no-store",
24+ },
1525 proxy: {
1626 "/api": {
1727 target,