meilisearch / meilisearch-js

JavaScript client for the Meilisearch API
https://www.meilisearch.com
MIT License
703 stars 85 forks source link

Switch package manager to `pnpm` #1660

Closed flevi29 closed 1 month ago

flevi29 commented 1 month ago

A lot of high profile repositories these days use pnpm.

The list goes on.

We could just upgrade yarn, but I am more familiar with pnpm and I generally see that pnpm is more popular these days, although their latest version is not on npmjs, so it's not really trackable. Speed seems to be on par, with pnpm having a slight edge perhaps (https://pnpm.io/benchmarks) https://p.datadoghq.eu.

Lockfile can be transformed.

We can also use the latest and greatest corepack features of Node.js.

curquiza commented 1 month ago

Hello, I saw discussion here, but I answer in this issue for an easier traceability with community: I'm not sure this change is worth it. We would like to keep what is working and yarn is not deprecated and still widely used. We want to avoid pain and work in order to focus on the most critical things. I'm afraid of the new pains this huge change could bring.

However I agree with you @flevi29, updating yarn could be a good move

Would love to have the opinion of the community of this

flevi29 commented 1 month ago

I'm not so sure about this huge pain and work. I detailed in the PR in my last comment that this will not be the case because of how corepack works, that's literally the whole point of corepack. EDIT: Sorry if I'm being rude.

Anyhow, the way I see it, to upgrade you'll still need to change actions/setup-node@v4 to enable corepack instead of installing yarn globally. Read on Yarn's page more: https://yarnpkg.com/getting-started/install

flevi29 commented 1 month ago

Alright fair enough, switching to pnpm might be a little much, I'll open another issue for updating yarn.

flevi29 commented 1 month ago

Closed in favour of #1664.