Surma

Surma

@surma.dev

DX & monorepo at Shopify. Craving simplicity, finding it nowhere. Internetrovert 🏳️‍🌈 He/him.

3.1K followers88 following64 posts

Pinned

📝 First blog in a long time! I always like “flow-based” programming, and it’s a very powerful paradigm. LangGraph lets you codify complex workflows as graphs, and also integrates really well with LangChain, if your workflow is LLM-driven. surma.dev/things/langg...

surma.devLangGraph for complex workflows — surma.devI may be late to the party, but LangGraph lets you build complex workflow architectures and codify them as powerful automations. Also LLMs, if you want. But you don’t have to!

This became real a lot quicker than I thought 😂 There's also a talk about this tomorrow at PlanetNix! bsky.app/profile/surm...

Surma@surma.dev

Nix friends: How terrible is this idea? I added `builtins.runWasm` to nix, allowing you to call out to Wasm. The Wasm is reset every time, so the functions remain pure. This gives you a (performant?) escape hatch for things that Nix is missing. E.g parsing YAML (here: via Rust)

Surma reposted

do you like geology puns and have an unhealthy obsession with package management? 🌋📦 we’re building a nix-based monorepo build system (in Rust!) at Shopify and we’re hiring. global, remote, high-autonomy. DMs open. www.shopify.com/careers/soft...

shopify.comSoftware Engineer - Monorepo Systems (Rust & Nix)ARE YOU READY? Join the fully-remote rocketship. Find your next quest to make commerce better for everyone. Unlimited growth. Crafters and hard workers only. Apply within.

Surma reposted

I dug into progressive image rendering and found a bunch of common assumptions aren't quite true. ➡️ JPEG & WebP progressive-renders worse in Safari ➡️ AVIF _does_ support progressive ➡️ But JPEG XL in Safari doesn't ➡️ JPEG XL decodes much slower than AVIF ⬇️ and more jakearchibald.com/2025/present...

jakearchibald.comThe present and potential future of progressive image renderingExploring progressive image rendering across JPEG, PNG, WebP, AVIF, and JPEG XL.

You know your JS13k submission is going well when you have to resort to `btoa` and other seemingly stupid hacks to get below the file size limit.

Surma reposted

if this type of thing makes you say “this is cursed af, where do i sign up” DM me, we’re looking for some teammates

Surma@surma.dev

Nix friends: How terrible is this idea? I added `builtins.runWasm` to nix, allowing you to call out to Wasm. The Wasm is reset every time, so the functions remain pure. This gives you a (performant?) escape hatch for things that Nix is missing. E.g parsing YAML (here: via Rust)

Nix friends: How terrible is this idea? I added `builtins.runWasm` to nix, allowing you to call out to Wasm. The Wasm is reset every time, so the functions remain pure. This gives you a (performant?) escape hatch for things that Nix is missing. E.g parsing YAML (here: via Rust)

Surma reposted

ECMAScript excitement 😉 Congrats to @bakkot.com on advancing UInt8Array ↔️ Base64/Hex to Stage 4 at TC39 this week 🎉 UInt8Array.prototype. toBase64 toHex UInt8Array. fromBase64 fromHex It lets you convert directly between binary data and Base64/Hex strings 👍

Unexpected dangers of vibe coding: Somehow git ended up tracking its own .git folder and now I can't commit anymore :3

Still discovering new shell tricks. TIL: Substitutions. `cmd <(cat file)` invokes `cmd` with the first parameter being a named pipe (e.g. `/dev/fd/22`) which contains the contents of `file`. Example use-case: You wanna diff two files, but they are binary so need disassembling

Scheduled a pickup with DHL, they never arrived and I can’t schedule a new pickup time. Went to website and clicked on “Help & Support”. It shows this in response. 10/10 would Lorem Ipsum again.

(⚠️ Definitely one of the dumber things I have written) This ES6 Proxy lets you instantiate any WebAssembly module without having to care about every import it requires. It generates an empty function for the ones you don’t provide. gist.github.com/surma/da12f7...

I really wanted to know which libraries are bloating my WebAssembly binaries, so I wrote a visualizer. Throw in a .wasm file with DWARF debug symbols, and wasmphobia will generate a flame graph for you, breaking down the module by source file. wasmphobia.surma.technology

Trying to get started with Kubernetes. Slightly annoyed by the cyclic “you should know about X first” in the docs 🙄

Just found a great show-case of AbortController. I don’t think I could make this code as concise without aEL’s support for AC signals. Note that I need to: - access `controller` from within the listener, - access `this` in `start()` - remove the listener in `cancel()`

One of my biggest upsets with getting more into smart home & automation is the hard data that my washing machine's "TurboWash 59" program takes 65 minutes.