Whip up a QR code that can be scanned by anyone with a smartphone or a QR code reader. All thanks to the awesome headless-qr module by Rich Harris. | Continue reading
Small widget to explore the data available when you paste or drop something on a web page. | Continue reading
Starting with macOS Catalina, Apple switched the default shell from Bash to Zsh. Also, the built-in version of Bash is horribly outdated. No bueno. | Continue reading
I find it useful to have a bootable USB lying around, in case I need to do a clean install, or recover from catastrophic failures. | Continue reading
I’ve been playing with terminal color schemes lately, and wanted a way of quickly previewing my changes, so I built this. | Continue reading
My kids love Baby Smash!, a Windows app that draws letters and shapes, and plays sounds, as they smash the keyboard and mouse. This is a crude attempt to replicate it using web technologies. We can’t capture certain key combinations and gestures, so it’s not very baby-safe. | Continue reading
Plotting the Mandelbrot set with a GLSL fragment shader. I’ve translated the code I wrote for plotting the Mandelbrot set with p5.js to a GLSL 1.0 fragment shader. The main difference is that I’m using vec2 to represent complex numbers, which makes things a bit more concise. | Continue reading
Plotting the Mandelbrot set with AssemblyScript, a TypeScript-like language that compiles to WebAssembly bytecode. I’ve translated the code I wrote for plotting the Mandelbrot set with p5.js to AssemblyScript, to get a feel for it. | Continue reading
The Mandelbrot set, named after Benoit Mandelbrot, is the set of complex numbers $c$ for which the function $f_c(z)=z^2+c$ does not diverge to infinity when iterated from $z=0$. I’m using the pseudocode from the Wikipedia article Plotting algorithms for the Mandelbrot set as base … | Continue reading
Did you know you can inspect any WebView on any macOS app, just by right-clicking it? | Continue reading
I was reading MDN’s article on signaling and video calling, and encountered this part: WebRTC is a fully peer-to-peer technology for the real-time exchange of audio, video, and data, with one central caveat. A form of discovery and media format negotiation must take place, as dis … | Continue reading
I wanted to compress some large strings in JavaScript, for an experiment with WebRTC, and found the excellent lz-string by pieroxy. It’s fast, and it weighs just a little over 4KB if you run it through something like Terser. I’ve tweaked it ever so slightly for my needs, but it s … | Continue reading
The prime spiral, also known as Ulam spiral, is a neat visualization of prime numbers devised by mathematician Stanisław Ulam. | Continue reading
Decode JSON web tokens right in the browser. Nothing gets recorded, everything is done client-side. | Continue reading
Using the Web Audio API to generate noise of different colors. | Continue reading
You know that cool animation that Polygon used in their Xbox One and PS4 reviews, where SVG images appeared to draw progressively? It’s really easy to do. | Continue reading
I’ve been playing with a few other scaling algorithms in the 2dimagefilter project. They produce even more impressive results than the previous batch. | Continue reading
I’ve been playing with a few scaling algorithms in the 2dimagefilter project. They produce impressive results when fed pixel art, and the fact that emulators can run them in real-time is just mind-boggling. | Continue reading
Small widget to compare two images side by side, for my articles on pixel art scaling (parts one and two). | Continue reading
Small widget that simulates a magnifying glass, for my articles on pixel art scaling (parts one and two). | Continue reading
Drawing a Lorenz attractor by absolutely positioning span elements along the x and y axes, and faking the z axis by adjusting their size. | Continue reading
Drawing a Lorenz attractor with CSS shadows. No JavaScript involved. | Continue reading
Rotating 3D shapes with CSS transforms and animations. No JavaScript involved. | Continue reading
Have you ever found yourself needing trigonometric functions like sine, cosine, and tangent when writing your Sass stylesheets? Ok, probably not, but the day may come, and you’ll be glad you read this. | Continue reading
You know those ‘Fork me on GitHub’ ribbons that you often see on websites for open source projects? Tom Preston-Werner released them in December 2008! Gosh, I feel old. | Continue reading