opened 03:34AM - 02 Oct 24 UTC
PNPM monorepos use a `pnpm-workspace.yaml` file to define packages, which can in…clude glob patterns. When running PNPM commands locally or using `--filter @testrepo/dep01`, everything works correctly from the root directory. However, when using Rewatch, these packages fail to resolve.
I've forked the `testrepo` repository and configured it with PNPM: https://github.com/hellos3b/rewatch-pnpm
From my investigation, Yarn hoists all packages to a root `node_modules`, whereas PNPM uses symlinks to cache dependencies as part of its core functionality. If Rewatch is relying on package resolution from 1node_modules1, it may be missing the symlinked dependencies.
Since PNPM is included with Node through [Corepack](https://nodejs.org/api/corepack.html), it seems reasonable to add direct support for PNPM resolution.