Biggest WTF news I’ve read today. I’m not a web dev so this doesn’t affect me, but this is bizarre.

We get a closer first look at what’s around the corner for AI coding tools, and make Bun better for it

This incredibly popular tool is now going to merge with an AI company and shift gears to be turned into some forced AI hype machine. Yipee! Exactly what all the devs were hoping for! /s

  • spartanatreyu@programming.dev
    link
    fedilink
    arrow-up
    23
    ·
    2 months ago

    Serious question for anyone who actually uses Bun:

    Why are you using Bun instead of Deno or Node?

    If you would have asked me 10 years ago, what were the biggest problems with JS as a whole, I would have stated:

    1. Poor type safety

    2. No standard library which leads people into dependency hell

    3. Poor security (installing a project should not even allow the possibility of key stealing or ransomware)

    4. No runtime ergonomic immutable data structures with fast equality checks (looked like it was going to be resolved with the Records and Tuples proposal, but it was withdrawn and discussions are continuing in the composites proposal)


    Today I consider point 1 mostly resolved and point 4 a problem for TC39 and engine implementers, and not resolvable by runtimes themselves.

    That leaves us with problems 2 and 3.

    I see Node having poor solutions for 2 and 3.

    I see Bun having poor solutions for 2 and 3.

    I see Deno having great solutions for 2 and 3.


    As far as I can tell, people have chosen Bun for either hype or speed reasons.

    Hype doesn’t seem like an important reason to choose Bun since it’s always fleeting and there’s enough investment in the industry to keep each runtime going for a long time.

    I do see speed being a moderate issue with JS, but that’s mainly due to:

    • dependency install times which should be a one time cost, and which can be reduced anyway by using a standard library

    • slow framework slop, which isn’t really a runtime issue.

    So I’m not sure speed fits as a reason for choosing Bun.

    I’m not sure what the other reasons are, but I’m genuinely curious.

    If you’re using Bun in projects today, why have you chosen bun?

      • spartanatreyu@programming.dev
        link
        fedilink
        arrow-up
        2
        ·
        2 months ago

        Pretty sure Deno had that first though.

        Deno launched with an all-tools-in-one approach and then you could use deno bundle to compile everything into a single binary that you could run on another machine.

        Then they briefly broke deno bundle in their 2.0 release when they added node/npm compatibility then brought it back in 2.4.

    • Juanjo Salvador@programming.dev
      link
      fedilink
      arrow-up
      2
      ·
      2 months ago

      I don’t know many people who choose Bun instead of Node or Deno, but all of them do it because speed.

      IMHO, I like Deno because it’s offering solutions for everything and trying to not fall into same issues Node had (same creator, trying to apologize), but eventually I run into Node because TypeScript and easy-to-use (in my experience). Anyway, Bun always has been to me like the third wheel of the bike.

  • fubarx@lemmy.world
    link
    fedilink
    arrow-up
    16
    arrow-down
    2
    ·
    2 months ago

    It’s not a bad outcome. Bun is cool but has $0 revenue and some hand-wavy thing about future paid cloud services. This way, larger companies will give them a more serious shot than they would a small startup.

    It still doesn’t have a revenue story, but it’s now strapped onto the side of one of the few AI companies with a decent chance of surviving the next AI Winter. And if Anthropic goes sideways, the Bun engineers can fork the code and keep going.

    • planish@sh.itjust.works
      link
      fedilink
      arrow-up
      1
      ·
      2 months ago

      Why does Anthropic think they need a JS runtime though? Are they just like “well Microsoft has a command line tool for installing JS packages so we need one too”???

      • fubarx@lemmy.world
        link
        fedilink
        arrow-up
        1
        ·
        2 months ago

        On the AI coding IDE side, VSCode has pretty much hoovered up everyone, mainly because JetBrains offered their own AI option, which kept competitors away. On the server side, though, integrating with AI is still wide open.

        You eventually have to hit Python because of all the ML libraries. But you can run that as a separate microservice or process. Here’s a chance to do something whacky, like let JS invoke Python-ML inline, or port the main ML libraries to JS, or cross-compile JS to CUDA (just spit-balling here). It’ll be a lot easier to try these experiments than trying to push it upstream into Node.

        Plus, Bun is used by a bunch of cross-platform CLI tools, including Claude Code, so they can make sure there are no breaking changes.

        TBH, I’m surprised nobody’s snapped up Mojo (and Chris Lattner). They have a lot more advanced, AI-relevant, cross-platform tech.

  • e8d79@discuss.tchncs.de
    link
    fedilink
    arrow-up
    9
    ·
    2 months ago

    People who are surprised by VC funded software going to shit…

    Funniest thing I I’ve seen in ages.

    Seriously, this always happens. At some point the investors want a huge payout and they will get it by exploiting existing users or they just shutdown the whole company and strip it for parts.

  • Buddahriffic@lemmy.world
    link
    fedilink
    arrow-up
    8
    arrow-down
    2
    ·
    2 months ago

    For anyone wondering wtf Bun is, it’s a project championing JavaScript. It wants to replace node.js.

    On a tangent, I recently switched from a cinnamon desktop (which uses TypeScript or some form of js) to KDE-plasma because I noticed that cinnamon occasionally couldn’t keep up with rapid mouse movements (and my machine is high end). KDE-plasma handles it fine and even has a “find my mouse” feature that turns doing the “draw fast circles to see if the mouse drifts all over the screen because the handler can’t keep up with the updates” into a game of “how big can I make the cursor”.

    I wish the whole “let’s keep javascript as a thing” movement would just die out. Other languages aren’t hard to learn, why are so many people obsessed with sticking with js and shoehorning fixes for its massive flaws instead of just letting it die?

    • myotheraccount@lemmy.world
      link
      fedilink
      arrow-up
      5
      arrow-down
      1
      ·
      2 months ago

      Not saying it should be used for everything, but it is a pretty decent language nowadays (lots of the annoying parts have been fixed in the last 15yrs). Although the main benefit imho is, that it is the closest thing we have to an interpreted language that runs everywhere.

      • Buddahriffic@lemmy.world
        link
        fedilink
        arrow-up
        4
        ·
        2 months ago

        Isn’t Python also widely supported these days?

        Though I’ll always prefer compiled languages over interpreted and I think cross compiling is also in the best state it ever has been, though dependencies can complicate things still, as well as any inline assembly use.

        • myotheraccount@lemmy.world
          link
          fedilink
          arrow-up
          4
          ·
          2 months ago

          Supported as in “you can install an interpreter on most machines”: yes

          But for JS it’s already there. You can just write a program, upload it someone, send someone a link and it runs. And it’s even sandboxed.

          (Although thanks to webassembly, that will be true for many more languages as well, so maybe my argument is void)

  • Taevas@beehaw.org
    link
    fedilink
    arrow-up
    6
    ·
    2 months ago

    Man, Bun’s great, I’ve been using it since 1.0.0 essentially so that REALLY sucks

    Like some of the other people commentating on this thread, I’ll look into using something else, but it’s really sad and frustrating that I need to switch things over and over again

  • clif@lemmy.world
    link
    fedilink
    arrow-up
    3
    ·
    2 months ago

    Damn it. I’ve been following bun for a long time and using it casually… Guess it’s good I didn’t get too far into it

    • SleeplessCityLights@programming.dev
      link
      fedilink
      arrow-up
      1
      ·
      2 months ago

      These statements can sum up most of what happening. Companies are always trying to make number go up. Ai is the new fad and they feel that if they don’t use Ai, their number won’t go up as much as their stakeholders expect it to. To not look bad to their stakeholders they jam in Ai anywhere they can fit it, but they don’t know what Ai is or how to use it. I believe this is the case where the how to use it is known however it is a shit tool that codes badly and does not actually understand code, just what is the most probable token to output next.