9 ms·
> If there are clearly better algorithms, why not refactor npm and add them in experimental flags to npm While node_modules has many flaws, in the current ecos
by arcatek 4y ago
> If there are clearly better algorithms, why not refactor npm and add them in experimental flags to npm
While node_modules has many flaws, in the current ecosystem all modes have their own pros and cons, and there isn't a "clearly better" algorithm: node_modules has less friction, PnP is sounder, and pnpm's symlinks attempt to be kind of an in-between, offering half the benefits at half the "cost".
Like in many computer science things, it's tradeoffs all the way. Part of why Yarn implements all three.
- zkochan 4y agopnpm also implements all three: https://pnpm.io/feature-comparison https://pnpm.io/feature-comparison But I think it is best to use Yarn for PnP and pnpm for the symlinked node_modules structure.