Try this. Find a photo on your phone that you love. Now squint, or zoom out until it's the size of a stamp. It's still the same photo. You can still tell what's in it. But something about it has gone a little flat — the part that made you take it in the first place has quietly walked out of the room. Most of us would describe what just happened with a shrug: "it's just smaller." But the truth is m
My Hugo blog was downloading 3.6 MB of JavaScript and 40 KB of external CSS on every page load. For a static blog with mostly text and a few diagrams, that was absurd. Here is how I fixed it. HTML: 86 KB JavaScript: 3.6 MB (Mermaid + KaTeX) CSS: 40 KB (KaTeX stylesheets) Problem: render-blocking scripts loaded on every page for math and diagrams Adding minifyOutput = true to hugo.toml shrunk HTML