Adding dynamic features to an aggressively cached website
AI-generated summary of reporting by Simon Willison’s Weblog. Read the original for the full story.
Why it matters
Shows developers how to add personalization and dynamic UI to fully CDN-cached sites using client-side localStorage tricks, plus evidence of building features entirely via Claude Code from a phone.
Simon Willison, a well-known developer blogger, explains how his Django-based blog adds interactive features despite Cloudflare caching every page for 15 minutes. He hides an 'Edit' button that only appears for himself by checking a localStorage flag in the browser, and adds a 'Random' button that jumps to a random post within a topic tag. He built the random-navigation feature entirely using Claude Code while prompting from his iPhone.
Willison's blog runs behind Cloudflare with a 15-minute cache to survive traffic spikes, which normally rules out any dynamic behavior. He solves this client-side: a browser-side localStorage key reveals admin-only edit links, and a random-tag navigation feature works by checking a timestamped localStorage value within a 5-second window. The takeaway is that aggressive caching and personalization can coexist cheaply, and the whole feature was built with Claude Code from an iPhone.
A Django site behind Cloudflare's 15-minute cache uses two localStorage patterns. Edit links: JavaScript checks an 'ADMIN' key on DOMContentLoaded and injects links from data-admin-url attributes; a custom Django admin checkbox toggles it. Random navigation: /random/TAG/ selects a random post across four content types via a SQL CTE (replacing an order-by-random union that didn't scale to thousands of tags), marks it no-cache, 302-redirects, and a header button persists if random_tag's timestamp is under 5 seconds old. Built via Claude Code for web; full transcripts linked.
Read the original
This summary exists to save you time, not to replace the source.
Key terms
Was this summary useful?
One click, anonymous. It tells us which summaries to re-run.
Related reading
Code-driven AI illustrations are more useful than images from dedicated image models
Code-driven AI illustrations let designers edit assets directly in code, saving time on iteration and ensuring consistency, which is a game-changer for teams that need rapid, reusable visual content.
A hierarchical note-taking app for building large personal knowledge bases
Trilium lets users build and navigate massive personal knowledge bases without duplicating content, saving time on organization and retrieval.
Desktop apps in Go with native UI or web frontend
Go developers can now ship cross-platform desktop and mobile apps in a single small binary without cgo or heavy runtimes, cutting build complexity and deployment size.
OpenBitFun: an agent workspace with four harness modes and phone remote control
OpenBitFun lets agents run on any machine and be controlled from a phone, eliminating the need to choose between local power and remote access, saving developers time switching contexts.
Intel One Mono: a monospaced font designed with low-vision developers
Developers with low vision or eye fatigue can read code more clearly, reducing errors and improving productivity.