Skip to content

v0.9.0 – browser cache policy, EmDash 0.35.0, caching guide

Choose a tag to compare

@vhscom vhscom released this 31 Aug 09:50
· 8 commits to main since this release
17fa43c

Public pages now tell browsers how long to keep them, search results stay out of the cache, and the README explains how the theme's caching actually works.

Known issue

The self-hosted build does not start in this release. node ./dist/server/entry.mjs exits immediately with TypeError: Cannot read properties of undefined (reading 'getLogger'). This release raised the Astro floor without moving @astrojs/node alongside it, and 11.0.2 reads an internal that Astro 7.2 relocated. The Cloudflare deploy is unaffected. Fixed in 0.10.0 — or pin @astrojs/node to ^11.1.4 yourself.

Heads up

  • Set Browser Cache TTL to "Respect Existing Headers" in Cloudflare, under your domain → Caching → Configuration. The theme now sends a Cache-Control on every page, but where the zone holds its own fixed value Cloudflare serves whichever is higher, so a four-hour default silently replaces the theme's five minutes. Neither half works without the other, and the override shows only on cached responses, so a cache-busted request looks correct.
  • EmDash 0.35.0 runs database migrations the first time you start the site after updating.
  • Astro 7.2.5 or newer is now required. Older versions could cache a signed-in visitor's page for everyone.

Fixed

  • Pages tell browsers how long to keep them, and missing pages say one minute. Without a header the host decided, so an edit stayed invisible to returning readers for four hours with no way to clear it. A browser cache cannot be purged.
  • Search results are no longer cached. They are built from whatever the reader typed, so they belong to nobody else.

Changed

  • EmDash 0.34.0 to 0.35.0, Astro 7.0.7 to 7.2.9. The declared floors move with them, not just the lockfile, so a fresh scaffold cannot resolve below the versions this release depends on.

Documentation

  • The README explains how the theme caches pages, what to set in Cloudflare before deploying, and why a page you have just deployed can still look old.

Full changelog: v0.8.0...v0.9.0