class

Hwaro::Services::OgLazyImageHandler

Inherits HTTP::Handler < Reference < Object

Dev-only on-demand OG image generation for [og.auto_image] lazy_generate = true under hwaro serve.

Lazy serve builds assign each eligible page its predicted og:image URL without rendering the file (OgImage.assign_lazy_urls) — this handler fulfills the promised "generated on first request" contract that previously didn't exist (the URLs 404'd all session). A request for a path under the OG output directory generates the owning page's image, then falls through to the static file handler to serve it from disk.

Only ever mounted in the dev handler chain; a no-op unless the current config enables auto-OG with lazy_generate.

Constructors

new(builder : Core::Build::Builder, output_dir : String)
Source

Instance methods

call(context)
Source