News for hackers. Stuff that matters.
Re:Hello Yarn 2, Goodbye node_modules by wilg on Monday August 09, 2021 @06:44PM (#28123232)
There are I'm sure valid reasons for doing it, but it fragments an already fragmented ecosystem. And IMHO it is ideal for there to be a first-party solution like Ruby/Bundler, Rust/Cargo, Swift/SPM, etc.
Re:Hello Yarn 2, Goodbye node_modules by dragonwriter on Monday August 09, 2021 @08:16PM (#28123892)
> And IMHO it is ideal for there to be a first-party solution like Ruby/Bundler

Bundler, AFAIK, isn't first-party, its a separate team and project.

Historically, IIRC, gems wasn't even first-party

Good standard solutions are often the outcome of multiple competing efforts pushing forward, proving what works, and proving what doesn't.

Re:Hello Yarn 2, Goodbye node_modules by wilg on Monday August 09, 2021 @08:25PM (#28123950)
Bundler is part of Ruby since 2018: https://github.com/ruby/ruby/commit/59c8d50653480bef3f245172...

But, it's irrelevant. I'm not arguing no one should make a third-party package manager, just that there should be a standard, ideally first-party one, that is good and well supported.

Languages like Ruby, Rust, Swift have recognized it is beneficial for the core project to provide a package management solution.

Re:Hello Yarn 2, Goodbye node_modules by imbnwa on Monday August 09, 2021 @06:48PM (#28123262)
Isn't the first party solution NPM?
Re:Hello Yarn 2, Goodbye node_modules by inopinatus on Monday August 09, 2021 @07:04PM (#28123406)
The first-party solution is ES Modules. Node is not Javascript.
Re:Hello Yarn 2, Goodbye node_modules by codetrotter on Monday August 09, 2021 @07:53PM (#28123750)
ES Modules aren't package management though? In that ES Modules say nothing about how to get the modules in the first place, nor anything about versions. Not in any standardized way anyhow.
Re:Hello Yarn 2, Goodbye node_modules by inopinatus on Monday August 09, 2021 @09:48PM (#28124394)
Solutions are defined by the problems they address, not the mechanics of how they address them, or even particularly how good or thorough they are.

Which is to say, yes, it’s painfully half-baked and riddled with inconsistencies. But that is pretty typical of JavaScript anyhow.

Re:Hello Yarn 2, Goodbye node_modules by codetrotter on Tuesday August 10, 2021 @05:17AM (#28126681)
> Solutions are defined by the problems they address, not the mechanics of how they address them, or even particularly how good or thorough they are.

Yeah but what I mean is that as it stands you literally cannot implement a package manager based on ES Modules alone. So it’s strange to me that someone would say that ES Modules are the package management solution for JavaScript. That’s not what it is currently for. Though the relevant standards may certainly be officially extended in the future, to allow for standardized package management based on ES Modules.

Re:Hello Yarn 2, Goodbye node_modules by inopinatus on Wednesday August 11, 2021 @04:02AM (#28139299)
No, that’s still fixating on the mechanics, not the problem. Package management is not a valuable outcome, it’s a means to an end.

In principle, ES modules do away with needing a package manager. And yes, folks are already working on the consequential gaps in capability.

The point still being, however incomplete it currently is, this is the first-party solution. Node is not JavaScript.

Re:Hello Yarn 2, Goodbye node_modules by kall on Tuesday August 10, 2021 @10:39AM (#28129415)
It still ships with node, right? So yeah.
Re:Hello Yarn 2, Goodbye node_modules by mbesto on Monday August 09, 2021 @08:43PM (#28124046)
You mean the npm, which is maintained by npm Inc., a subsidiary of GitHub (Microsoft)? IMO, that's where the problem lies.