Comment by koakuma-chan

Comment by koakuma-chan 10 hours ago

6 replies

I found mixing Bun and Rust works pretty well. Bun has gotten many cool new things recently which feel great to use and it has a nice FFI API. So I have Next.js apps running in Bun runtime and anything CPU bound is written in Rust and called via FFI.

pjmlp 9 hours ago

I would have expected Zig, given Bun, or using Deno instead, if Rust as extension language.

  • koakuma-chan 8 hours ago

    > I would have expected Zig

    You can use Zig instead if it meets your needs, but last time I checked, the Zig ecosystem was lacking compared to Rust.

    > or using Deno instead, if Rust as extension language

    Deno? There was a thread the other day that Deno is dead. I wouldn't even compare Deno and Bun because Bun is just waaay better. Even before Bun already felt very polished and nice to use, and now it even has native postgres and s3 clients. And it doesn't try to sell you a KV database or some shit.

    • pjmlp 8 hours ago

      The point I was making was using the same language the VM makes use of, instead of adding extra layers.

      • koakuma-chan 8 hours ago

        I mean, I guess there would be some point if you, e.g., forked bun and wrote new APIs in Zig. But if you are using FFI it doesn't really matter because the interface is C ABI anyway; there's no extra layers in using a language different from the one your runtime uses.

never_inline 7 hours ago

JS developer use tooling older than 3 years challenge. Level: impossible.

  • koakuma-chan 6 hours ago

    It's not only JS. The tooling was just trash everywhere before Rust started gaining traction. E.g. for Python there is uv now, and I am definitely not going back to freaking pip.