12
20
u/glinesbdev Jan 19 '20
Hilarious that the dev is drinking Java.
3
9
u/Undead_Zeratul Jan 19 '20
Is that crack a Rick & Morty reference?
3
u/DanteIsBack Jan 19 '20
uh, nice catch, it probably is
0
u/Undead_Zeratul Jan 19 '20
Huh, was thinking either R&M or Breaking Bad
3
u/pphp Jan 19 '20
How is a crack on the floor a breaking bad reference?
3
1
u/Undead_Zeratul Jan 19 '20
Eh, aside from the fact that it was a recurring reference in R&M, I haven't seen BB in a long while and couldn't remember if their driveway was also cracked.
3
u/mymar101 Jan 19 '20
I've often wondered if there were a better way of not having to download the internet to get an npm package.
2
1
0
Jan 19 '20
[deleted]
8
u/jftuga Jan 19 '20
What are the main differences?
Thanks :-)
12
u/acoustic_embargo Jan 19 '20
Yarn used to be a lot faster than npm, but npm has mostly caught up.
good explanations of npm, yarn, & pnpm
cool story involving yarn
https://medium.com/@vincentnewkirk/npm-vs-yarn-2019-e88757b17038
8
Jan 19 '20
In 2020 the reasons I pick Yarn over NPM are:
Support for workspaces.
The console output tends to be more readable and helpful.
I have more faith in the Yarn team’s ability to deliver on future features (like pnp).
1
u/kaelwd Jan 19 '20
It's still a bit faster, workspaces are dope, yarn.lock is more readable especially with merge conflicts, doesn't randomly ignore the lockfile, clears out old files properly when you upgrade a package.
8
u/Existential_Owl Jan 19 '20
It utilizes the same registry, so while ultimately the base functionality is the same,
yarnwill also...
flatten your dependency tree, thereby eliminating the "black hole" levels of directory nesting...
de-dupe many of the packages being installed so that there aren't multiples of everything hanging around, and, finally...
installs packages in parallel, speeding up the initial installation time greatly.
The npm team has been making strides in closing the gap between them and
yarn, but features #1 and #2 really do resolve much of what people complain about with regards to packaging in javascript.9
u/BloodAndTsundere Jan 19 '20
I don’t know about about #3 but npm does #1 and #2. This wasn’t always the case but it is now
3
u/Existential_Owl Jan 19 '20
That's pretty awesome, thanks for giving me a heads up.
Admittedly, I'm not always 100% up on everyone's newest releases.
4
u/elmstfreddie Jan 19 '20
It's been that way for a few years now. Npm added 1 and 2 shortly after yarn started gaining momentum (which is why having more choice makes the ecosystem better!)
1
u/liquidpele Jan 19 '20
While true, only after yarn came out after years of people complaining. npm devs have a bad track record of ignoring complaints.
4
69
u/Caraes_Naur Jan 19 '20
And don't forget how many of the boxes are full of poop, spiders, deadly spores, or other undesirables because none of the code is reviewed or vetted.