News for hackers. Stuff that matters.
Re:Bun 1.2 Is Released by rakatata on Thursday January 23, 2025 @07:30AM (#42803325)
s3 is pretty much a de-facto standard, just like json like or not. Postgres also makes sense, it is the most widespread and community-liked db. What is the point of "optional libraries" tbh? It was a PITA in PHP back in the days and very inconvenient, prob most devs would prefer this way.

I feel like HN is on cognitive dissonance, they complain JS projects having too many dependencies and they also complain now when things are more integrated into the runtime because it increases vendor-lock and few extra megabytes (actually kilobytes according to the devs) to the binaries :/.

Lastly, big companies also prefer less dependencies, it is not just devs.

Re:Bun 1.2 Is Released by chearon on Thursday January 23, 2025 @12:20PM (#42805886)
It probably looks very wrong to people who still think lots of "modularity" and small packages is a good thing.

I'm all for it, and lots of Bun APIs are purely practical. Bun.stringWidth, for example, exposes code Bun already has internally. Nodejs probably has the same thing, but instead of us being able to use it, it gets reimplemented in 10 different versions in node_modules. How is that better?

I doubt the Bun team will have to change the S3 code very much over the years. The test runner, bundler, Postgres client, sure, I can see those being harder to maintain. But I'm also tired of everyone assuming everything needs to change all of the time. DX aside, my team is still on Webpack and we've only needed one new feature from it in the last ~5 years. Why can't Bun's bundler reach maturity and only receive a few updates?

Re:Bun 1.2 Is Released by pfg_ on Thursday January 23, 2025 @03:59PM (#42807998)
Node does have the same thing, and you can access it with `--expose-internals` from `const { getStringWidth } = require("internal/util/inspect");`. They don't expose it for some reason.
Re:Bun 1.2 Is Released by 8n4vidtmkvmk on Thursday January 23, 2025 @08:22PM (#42809690)
I'm also still using webpack. Not sure why the community abandoned it. Haven't had any issues. Everything seems to use babel under the hood anyway and they all have their little wrappers over top.
Re:Bun 1.2 Is Released by Ygg2 on Thursday January 23, 2025 @07:53PM (#42809549)
> s3 is pretty much a de-facto standard

So was XML before, and SGML before it. De-facto changes over time, and backwards compatibility means your decisions are cast in stone.

In 20 years, you could see s3 being abandoned for newer formats, but bun will have to keep those packages.

Re:Bun 1.2 Is Released by 7bit on Friday January 24, 2025 @06:19PM (#42817890)
So? I mean, what ist the real downside, beside 5kb additional filesize?
Re:Bun 1.2 Is Released by Ygg2 on Saturday January 25, 2025 @12:37PM (#42823117)
Assuming backwards compatibility.

Ongoing maintenance burden. Ever increasing API, mistakes set in stone, subpar performance or properties.

"Standard library is where libraries go to die." exists as a saying for reason.

Re:Bun 1.2 Is Released by paulddraper on Thursday January 23, 2025 @08:15PM (#42809660)
> s3 is pretty much a de-facto standard

Finding documentation on that standard (particularly the edge cases) is very difficult

Re:Bun 1.2 Is Released by 8n4vidtmkvmk on Thursday January 23, 2025 @08:19PM (#42809673)
Back in what days of PHP? I've been using PHP and MySQL since... Probably 2003ish and never had a problem. I think you need the extension but most providers had it.