Request-scoped stateWorker
Useful persistence in a browser cookie.
This page reads a typed cookie, increments its visit count, and queues a Set-Cookie header on the response. Density persists across the whole showcase; dark mode is available in the header.
This banner is cookie-backed.
Dismiss it, refresh the page, and it stays gone.
CookieStore<T>
SameSite=LaxBrowser preferences
The cookie is HttpOnly and only carries non-sensitive demo settings.
Current payloadTyped Rust struct
What the Worker decoded
Malformed or missing data safely falls back to defaults.
- visits
- 1
- dark
- false
- density
- comfortable
- banner_dismissed
- false
Visit count increments on each GET.