Blog · page 6
Notes on engineering, design, and everything in between.
The autocorrect attribute: giving the page a say in auto-correction
Chrome 152 supports the global autocorrect attribute, Safari and Firefox had it already, and so it reaches Baseline. How it differs from spellcheck, why it spent years as a vendor prefix, and when you should turn it off.
Compressed and still mutable: a dynamic compressed self-index
Highly repetitive string data (genomes, web archives, versioned documents) compresses beautifully, but any edit forces a full rebuild. A RIKEN AIP paper at ESA 2026 proposes dynamic RR-index, the first to combine compression, search, and updates in delta-optimal space.
<template for>: letting HTML declare which region gets replaced
Chrome 150 supports the template for attribute: processing instructions mark replaceable regions, and streamed templates fill them. How it works, what it solves, and why it should not go anywhere near production yet.
The source shown on the page and the file served to curl must be one string
A scripts section has to display its source and also serve the identical file at /scripts/x.sh. Two copies drift. Why inlining with import.meta.glob and ?raw beats reading the filesystem at build time or copying into public.
Atomic file writes: write a temp file, then rename
Overwriting in place leaves half a file behind on power loss, a crash, or a concurrent read. A temp file plus rename uses filesystem atomicity to make half a file impossible.
Base64: it is neither encryption nor compression
Base64 turns 3 bytes into 4 printable characters, growing the payload by a third. It solves carrying binary through a text channel, not keeping anything secret.
