Sign in

Surma

@surma.dev
3.2K followers 88 following 64 posts

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

PostsRepliesMedia
Surma @surma.dev · 09/09/2025
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.
190
Surma @surma.dev · 04/09/2025
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)
180
Surma @surma.dev · 10/07/2025
Convince me I am wrong: This should not be a type error, right? - I asserted it’s an object - I am using `?.` for property access www.typescriptlang.org/play/#code/G...
1150
Surma @surma.dev · 28/03/2025
Unexpected dangers of vibe coding: Somehow git ended up tracking its own .git folder and now I can't commit anymore :3
3191
Surma @surma.dev · 26/10/2024
I love what keybr.com thinks Rust code looks like
190
Surma @surma.dev · 07/09/2024
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
0100
Surma @surma.dev · 08/08/2024
I find it remarkable that xkcd just casually invented the term "nerd sniping" in a comic, and it is now a completely normal word to use ... xkcd.com/356/
090
Surma @surma.dev · 04/07/2024
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.
090
Surma @surma.dev · 16/05/2024
(⚠️ 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...
030
Surma @surma.dev · 13/05/2024
I added experimental support for JavaScript sourcemaps (both inline and separate) to Wasmphobia. I liked the idea of making it a one-stop-shop for all your bundle analysis needs 😅 wasmphobia.surma.technology
030
Surma @surma.dev · 09/05/2024
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
073
Surma @surma.dev · 14/04/2024
Trying to get started with Kubernetes. Slightly annoyed by the cyclic “you should know about X first” in the docs 🙄
160
Surma @surma.dev · 11/04/2024
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()`
040
Surma @surma.dev · 07/04/2024
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.
060
Surma @surma.dev · 11/06/2023
First time actually playing with the new-ish Navigation API. developer.mozilla.org/en-US/docs/We… A very modern API. A lot more control. As a trade-off, not as trivial to implement correctly. First tripwire for me: `navigationEvent.intercept()` commits the new URL.
050