Tech News
← Back to articles

Electrobun v1: Build fast, tiny, and cross-platform desktop apps with TypeScript

read original related products more articles

Electrobun v1

Build ultra fast, tiny, and cross-platform desktop apps with TypeScript.

Two years ago I paused co(lab) to build the desktop app framework I wished existed. Now that I've shipped a stable v1, this post is me reflecting on this two-year sidequest that had me learning Zig, C, C++, and Objective-C.

Why I Built This

My intro to programming was Visual Basic 6 in the early 2000s, building desktop apps. Then Adobe AIR changed my life—I built a few startups and shipped desktop apps to thousands of people. That was the golden age for me. Fast forward 20+ years of zero-to-one work at startups, building and scaling key systems as early eng at unicorns shipping to 10s of millions, and starting my own startup lab; somehow desktop development had gotten worse. I was building co(lab), a hybrid web browser + code editor + PTY terminal, and I just ran into one papercut too many.

The first version was built in Electron. The DX was rough—figuring out code signing, notarization, distribution, and updates felt like fighting the framework instead of building my app. I wanted to ship like the web, continuously, but every piece of the toolchain made that harder than it needed to be.

I tried Tauri but Rust is not for everyone. Bun was up and coming, still months away from 1.0. So I got to work.

From macOS to Everywhere

When Electrobun started, it only built macOS apps. Today it has first-class support for building on and distributing to macOS, Windows, and Ubuntu. Installers, auto-update artifacts, differential patches—all generated automatically. Bring your own static host (R2, S3, GitHub Releases) and you're done. The differential updates are powered by zig-bsdiff, which I ported from C to Zig and optimized with SIMD and zstd.

As Bun's FFI stabilized, I replaced most of the Zig FFI layer I'd written and leaned on Bun directly. The architecture inverted in a good way—Bun uses shared memory when spinning up workers, so Electrobun stays efficient even with multiple processes.

... continue reading