Surma's Avatar

Surma

@surma.dev

DX & monorepo at Shopify. Craving simplicity, finding it nowhere. Internetrovert πŸ³οΈβ€πŸŒˆ He/him.

3,100
Followers
86
Following
63
Posts
19.05.2023
Joined
Posts Following

Latest posts by Surma @surma.dev

This became real a lot quicker than I thought πŸ˜‚

There's also a talk about this tomorrow at PlanetNix!

bsky.app/profile/surm...

05.03.2026 19:46 πŸ‘ 2 πŸ” 0 πŸ’¬ 0 πŸ“Œ 0
Preview
A new chapter for the Nix language, courtesy of WebAssembly Determinate Nix now supports Wasm functions in Nix expressions, bringing a range of new possibilities to the Nix ecosystem

`builtins.wasm` is now a (experimental) thing in @determinate.systems’ nix, with a PR open for upstream nix.

This lets you extend the nix language by compiling C/C++/Rust/etc into safely sandboxed, platform-independent plugins!

determinate.systems/blog/builtin...

05.03.2026 19:44 πŸ‘ 4 πŸ” 0 πŸ’¬ 1 πŸ“Œ 0

What a flex :D

Fwiw, it was similarly easy on the spec side. The algorithm was fully spec’d, just not attached to any globals. And after the spec was written, it took 3 years or something for browsers to go β€œwell I suppose this is kinda useful?” πŸ˜‚

23.10.2025 11:55 πŸ‘ 0 πŸ” 0 πŸ’¬ 0 πŸ“Œ 0
Preview
Software 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.

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...

16.10.2025 14:56 πŸ‘ 13 πŸ” 1 πŸ’¬ 1 πŸ“Œ 0

Thank you!! Fixed :)

16.10.2025 21:06 πŸ‘ 1 πŸ” 0 πŸ’¬ 0 πŸ“Œ 0
Preview
Software 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.

I have been working on the nix & Rust codebase that builds Shopify’s monorepo, and there’s so much left to do that we need help.

If you are interested, apply here to join us! DM me if you have questions!

www.shopify.com/careers/soft...

16.10.2025 16:20 πŸ‘ 17 πŸ” 3 πŸ’¬ 1 πŸ“Œ 0
Preview
The present and potential future of progressive image rendering Exploring progressive image rendering across JPEG, PNG, WebP, AVIF, and JPEG XL.

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...

16.10.2025 10:16 πŸ‘ 173 πŸ” 42 πŸ’¬ 15 πŸ“Œ 6

It can handle 400 megapixel manga like no other

07.10.2025 16:42 πŸ‘ 16 πŸ” 0 πŸ’¬ 1 πŸ“Œ 0

JSConf.eu throwback for me

27.09.2025 18:03 πŸ‘ 3 πŸ” 0 πŸ’¬ 1 πŸ“Œ 0

Take a look at ImHex!!

14.09.2025 20:31 πŸ‘ 0 πŸ” 0 πŸ’¬ 1 πŸ“Œ 0

This is so perfect for you. Can't wait to see you crush it.

13.09.2025 08:38 πŸ‘ 2 πŸ” 0 πŸ’¬ 0 πŸ“Œ 0

AlternativprojektsinterressantheitsverstΓ€rkung

10.09.2025 07:21 πŸ‘ 20 πŸ” 0 πŸ’¬ 1 πŸ“Œ 0

`enum` yes, `const enum` no. Gotta love TS sometimes :3

09.09.2025 11:04 πŸ‘ 3 πŸ” 0 πŸ’¬ 0 πŸ“Œ 0
Post image Post image Post image

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.

09.09.2025 09:45 πŸ‘ 9 πŸ” 0 πŸ’¬ 1 πŸ“Œ 0

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

06.09.2025 15:37 πŸ‘ 7 πŸ” 1 πŸ’¬ 2 πŸ“Œ 0

For now, I established the convention the the parameters must be pointers to byte arrays containing UTF-8 encoded JSON strings. I think that’s actually quite feasible.

But the real deal would be to use the Wasm component model imo

04.09.2025 16:03 πŸ‘ 2 πŸ” 0 πŸ’¬ 0 πŸ“Œ 0
Post image Post image

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)

04.09.2025 14:44 πŸ‘ 8 πŸ” 0 πŸ’¬ 1 πŸ“Œ 2
Preview
Making XML human-readable without XSLT JavaScript is right there.

πŸ“ Making XML human-readable without XSLT.

Turns out, JavaScript works pretty well!

jakearchibald.com/2025/making-...

02.09.2025 17:23 πŸ‘ 74 πŸ” 14 πŸ’¬ 6 πŸ“Œ 1

I guess I grouped all kinds of implementation bugs into the "interoperability" category. Probably not super fair to folks working on interop πŸ˜…

27.08.2025 16:38 πŸ‘ 2 πŸ” 0 πŸ’¬ 1 πŸ“Œ 0

I had to learn it for my UK citizenship test. I didn't do very well, just barely enough to pass.

27.08.2025 16:37 πŸ‘ 1 πŸ” 0 πŸ’¬ 1 πŸ“Œ 0

I mean, something working in one browser and not the other is a failure of either interoperability or specification.

27.08.2025 16:34 πŸ‘ 5 πŸ” 0 πŸ’¬ 2 πŸ“Œ 0

The thing is that Firefox on iOS is not even Firefox. But whenever I see multiple rAF's nested, especially with a setTimeout sprinkled in, I gotta summon Jake.

24.08.2025 09:35 πŸ‘ 12 πŸ” 0 πŸ’¬ 2 πŸ“Œ 0

@jakearchibald.com plz fix

24.08.2025 09:24 πŸ‘ 6 πŸ” 0 πŸ’¬ 2 πŸ“Œ 0
Me, sitting behind a cuddly toy of a fox. Ok it's obviously Firefox.

Me, sitting behind a cuddly toy of a fox. Ok it's obviously Firefox.

Starting my new role on Monday. Could be anywhere.

31.07.2025 12:57 πŸ‘ 412 πŸ” 14 πŸ’¬ 45 πŸ“Œ 5
let arr = new Uint8Array([72, 101, 108, 108, 111, 32, 87, 111, 114, 108, 100]);
console.log(arr.toBase64());
// 'SGVsbG8gV29ybGQ='
console.log(arr.toHex());
// '48656c6c6f20576f726c64'
let string = 'SGVsbG8gV29ybGQ=';
console.log(Uint8Array.fromBase64(string));
// Uint8Array([72, 101, 108, 108, 111, 32, 87, 111, 114, 108, 100])

string = '48656c6c6f20576f726c64';
console.log(Uint8Array.fromHex(string));
// Uint8Array([72, 101, 108, 108, 111, 32, 87, 111, 114, 108, 100])

let arr = new Uint8Array([72, 101, 108, 108, 111, 32, 87, 111, 114, 108, 100]); console.log(arr.toBase64()); // 'SGVsbG8gV29ybGQ=' console.log(arr.toHex()); // '48656c6c6f20576f726c64' let string = 'SGVsbG8gV29ybGQ='; console.log(Uint8Array.fromBase64(string)); // Uint8Array([72, 101, 108, 108, 111, 32, 87, 111, 114, 108, 100]) string = '48656c6c6f20576f726c64'; console.log(Uint8Array.fromHex(string)); // Uint8Array([72, 101, 108, 108, 111, 32, 87, 111, 114, 108, 100])

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 πŸ‘

30.07.2025 06:56 πŸ‘ 40 πŸ” 9 πŸ’¬ 1 πŸ“Œ 0

Super happy with hyperoptic

24.07.2025 21:26 πŸ‘ 1 πŸ” 0 πŸ’¬ 0 πŸ“Œ 0

Oh that's interesting. I wonder if this is from the merge of ChromeOS and Android.

Let me see if I can install nix :3

18.07.2025 17:25 πŸ‘ 3 πŸ” 0 πŸ’¬ 0 πŸ“Œ 0
Links? Links! - Infrequently Noted Alex Russell on browsers, standards, and the process of progress.

I spent hours and hours trawling through the sites of some of the world's best web developers, and despite the horrors I regularly experience in my daily work in Big JavaScript Territory, what I saw left me hopeful:

infrequently.org/2025/07/links/

16.07.2025 23:17 πŸ‘ 82 πŸ” 19 πŸ’¬ 6 πŸ“Œ 4

No, I'd want `x.a` to still be an error, which would not be the case with `any`. With `?.` I feel like I'm opting in to props that TS is not aware of

11.07.2025 14:29 πŸ‘ 1 πŸ” 0 πŸ’¬ 1 πŸ“Œ 0