An age old debate about package managers
Each have their pros & their cons
I personally prefer Yarn - I think it's general installation of packages is quicker and I REALLY appreciate its peer dependency resolution it saves LOADS of time.
So - what is your go-to package manager and why?
Oldest comments (76)
pnpm really fast installation ( in one monorepo I have 2,5 min vs 20 min in npm) and stricter in resolving dependencies. Also saves a lot of disk space if you have multiple projects.
I also use and enjoy pnpm. It's great for strictly resolving dependencies across the board, instead of recreating the wheel.
Is it really that good would you ever go back to npm or yarn? Or do you still use them sometimes?
If I can choose I always choose pnpm. But try them all and decided for your self :)
NPM, haven't tried yarn yet, I can wait few minutes while installing dependencies so don't think speed is that much of issue in NPM
NPM, because it has more community support. I'd rather have more compatibility between my tools rather than save 10 minutes on an installation I only do a few times a year.
I've been using yarn berry (v 3.2.1) and it's awesome!
Always been a fan of yarn, it's really useful to just write yarn command instead of nom run command
Δ± usually use yarn
npm for the moment, because of npx.
yarn dlx at the moment works bad.
P.S. I tried to work on nx.js monorepo framework, and it doesn't support yarn v3.
I was surprised that some libraries/tech-stacks must something to do for supporting yarn dlx or other yarn v3 features.
And npm working from the box with all libraries without any issues :)
Last time I used Yarn berry (Which was a couple weeks ago) I couldn't get it to install private packages from GitHub packages because it doesn't use your .npmrc like PNPM or NPM. Unfortunately for my case it wasn't a drop in replacement for NPM. So I use NPM for now. I like the interactive upgrade feature of Yarn and the node_module structure that PNPM has.
I usually resolve the dependencies manually and download zips myself π€£
Oh dear. I feel sorry for you. That must be a nightmare!
I have a dial up connection which makes it even worse!
Neat, sounds very manual :p
I can think of using this for c++ or so, but im curious.
It's only a joke, this is what they both do.
CPP has some package managers already I think, Conan or something, but there is no standard "package" last time I was working in CPP anyway
I see :p
and good to know as well, I do plan to start looking into vsti development (synths and such for DAWs) which mainly uses c++
A true old school hardcore developer! π
I joke but I can remember doing this! So many zip files, I can remember also when .min.js was a new choice!
Adam, I know and I can definitely relate, which makes it even funnier π.
I hope people don't feel bad for us being old π
PNPM all the way, unless for some reason I have to use something else for some reason.
Right now, PNPM is my only globally installed dependency. Everything else can be explicitly listed in each project without having to be reinstalled for each project, which has saved me from some CI headaches I ran into with NPM previously. (Like forgetting to list typescript, and having it work locally because of a global install but NOT work on CI because there are no global installs)
I know I sound like a fanboi, but its my happy place.
I heard NextJS has dependence graph problem.π€ it good and fast but not fully support some old projectπ₯²
npm is the one I use. I just never got around to trying out yarn or pnpm, but Iβve used yarn once to compile a repo that was based on it. But, I use mask to run the tasks in npm and external moving things around or setting up the compile with other command line commands.