News for hackers. Stuff that matters.
Re:Announcing NPM 6 by eberkund on Tuesday April 24, 2018 @10:43AM (#16912959)
Those performance improvements sound too good to be true, how does this compare to Yarn? Although these are all excellent features I am disappointed to see that there is no support for Yarn's "flat mode" which installs all dependencies in node_modules (and not endlessly nesting them).
Re:Announcing NPM 6 by jeremiep on Tuesday April 24, 2018 @01:01PM (#16914406)
They probably found some silly anti-pattern they were doing previously that was killing performance for no good reason.

The entire history of npm screams "we're pretty much learning all of this as we go, please bear with us".

While there's nothing wrong in that (people have to learn somehow) it does make it very, very hard to put any trust in that project. Especially when said project is at the very center of an entire ecosystem, it makes it hard to trust the ecosystem as well. I'm already seeing a lot of good developers move away from node as they gain experience and realize things should be much better.

Its pretty much standard for literally any project I've seen without senior devs to see these bugs before a release.

Re:Announcing NPM 6 by sveit on Tuesday April 24, 2018 @02:09PM (#16915044)
> I'm already seeing a lot of good developers move away from node as they gain experience and realize things should be much better.

What are you seeing them move to?

Re:Announcing NPM 6 by jeremiep on Tuesday April 24, 2018 @05:12PM (#16916650)
Mostly Go but some Rust and Clojure as well.

I converted a lot of developers to Clojure myself. That language is by far the most fun I've had writing software in almost two decades of experience, where the fun comes from having simple yet really powerful tools rather than easy-to-learn-but-generates-complexity ones.

Re:Announcing NPM 6 by Rapzid on Tuesday April 24, 2018 @09:41PM (#16918108)
TypeScript seems to have been attracting some srs engineering talent into the ecosystem. If your backend needs fit into the node.js box, TypeScript is pretty compelling as unifying front/back end language; at least as a starter pack.
Re:Announcing NPM 6 by jeremiep on Wednesday April 25, 2018 @12:44PM (#16923359)
I used TypeScripts for a few years in the past. That was before knowing about ClojureScript however :)

Having done projects in both languages the later is definitely much simpler and this translates into less code that does more. Its then much easier to maintain and add features.

Most of the JS/TS projects I see lose iteration speed over time, while CLJ/CLJS projects I see gain iteration speed over time.

Re:Announcing NPM 6 by jeremejevs on Tuesday April 24, 2018 @12:06PM (#16913798)
> npm@6 is up to 17x faster than the npm of one year ago.

I think by "npm of one year ago" they mean npm 4, since npm 5 came out last May. If so, "up to 17x" is plausible. But even though technically true, this is a cheap marketing move, IMO. If one doesn't read carefully, it may register as "npm 6 is 17x faster than whatever came out last year, that is npm 5".

Re:Announcing NPM 6 by always_good on Tuesday April 24, 2018 @10:51AM (#16913033)
How does it differ from the flat dependency support added in NPM 3?
Re:Announcing NPM 6 by heckanoobs on Tuesday April 24, 2018 @11:36AM (#16913473)
The perf improvents are real, I recently updated our build tools from npm3 to npm5 and it shaved minutes off. npm ci is a real treat as is reliable parallelism of npm i.

IMO yarn was a protest movement when npm wasn't adding the features devs wanted. npm5 is the direct result and yarn should pat itself on the back and bow out to avoid fragmenting the community.

Re:Announcing NPM 6 by ac2u on Tuesday April 24, 2018 @12:02PM (#16913773)
You make it sound like yarn was some sort of community a fork to plug some gaps.

Why should yarn bow out? Correct me if I'm wrong, but the yarn project didn't do the following: - put a pre-release build under a tag that looks like a normal build without a pre suffix - had documentation that expressed sudo as an acceptable way to do things to end users - then had a bug which torched machines if they ran any npm command under sudo. (which you shouldn't do anyway, but see point 2) - when pushing the fix, put hashtags in the announcements with a distinct tone of blame towards the end users.

Re:Announcing NPM 6 by sebazzz on Tuesday April 24, 2018 @01:31PM (#16914674)
> then had a bug which torched machines if they ran any npm command under sudo. (which you shouldn't do anyway, but see point 2)

This was the famous "rm -Rf /" bug.

> put hashtags in the announcements with a distinct tone of blame towards the end users.

What are you referring to?

Re:Announcing NPM 6 by Murrawhip on Tuesday April 24, 2018 @01:46PM (#16914791)
> What are you referring to?

Probably this: https://blog.npmjs.org/post/171169301000/v571

Re:Announcing NPM 6 by shawndellysse on Tuesday April 24, 2018 @02:38PM (#16915356)
Wow, that's very immature.
Re:Announcing NPM 6 by manigandham on Tuesday April 24, 2018 @11:44AM (#16913557)
> bow out to avoid fragmenting the community.

No thanks. NPM caused the usability and feature problems first and there's no reason it won't happen again if there was no competition. Yarn is still better overall and I'm much rather they stick around.

Re:Announcing NPM 6 by Touche on Tuesday April 24, 2018 @12:28PM (#16914057)
Yarn feels more stable to me. I don't know how many breaking changes they've made but it sure feels like fewer (the version 1.x shows that).

Also, I think npm released it's lockfile too quickly. It didn't work for quite a while. Maybe it does now, I don't know, because any npm projects I have I have turned off package-lock due to it not working in the past. Yarn's lockfile just works, and always has.

So I'll stick with Yarn as long as they just keep it stable the way it is.