Questions tagged [pnpm]
pnpm uses hard links and symlinks to save one version of a module only ever once on a disk. When using npm or Yarn for example, if you have 100 projects using the same version of lodash, you will have 100 copies of lodash on disk. With pnpm, lodash will be saved in a single place on the disk and a hard link will put it into the node_modules where it should be installed. As a result, you save space on your disk and you have a lot faster installations!
pnpm
500
questions
0
votes
0
answers
20
views
How to ensure that dependencies are not missing when using pnpm & tsc?
I have a project that uses pnpm and tsc. I've noticed that if I don't change the source code but I tamper with the dependencies then tsc will not rebuild the project only when I change the actual ...
1
vote
1
answer
45
views
Efficiently Managing Shared Dependencies and Binaries in a pnpm Monorepo Workspace
I'm working on a monorepo setup using pnpm workspaces to manage multiple related projects. My goal is to efficiently manage and share dependencies across these projects without duplicating them in ...
0
votes
1
answer
30
views
NextJS build error with typescript index signature
When I do pnpm run build I got this error:
✓ Compiled successfullyLinting and checking validity of types ..Failed to compile. .next/types/app/components/button/addNew/page.ts:
Type error: Type '...
0
votes
1
answer
19
views
Ambient declarations work, but `declare global` is lost in a monorepo workspace using pnpm
When I import a function from another package, it loses its type definition. The type is defined globally within that package. Other types work fine. How can I solve it?
It is necessary to say that I ...
0
votes
1
answer
22
views
How to develop with an external npm package into a Yarn PnP monorepo?
I do have to work with a large Yarn PnP mono repo (~30 packages and 3 micro apps).
One of the packages (package-b) is using an external npm package package-a (which is using npm as a package manager) ...
4
votes
2
answers
2k
views
pnpm/action-setup self installer issue
I've been running pnpm/action-setup@v2 for awhile now, but I started getting this error.
Running self-installer...
WARN GET https://registry.npmjs.org/pnpm error (ERR_INVALID_THIS). Will retry in ...
-1
votes
0
answers
31
views
Use pnpm commands in workflow from caller setup
Attempting to abstract out setup steps from a CI workflow. With pnpm and node installed in a separate setup.yml caller within my project's ./.github/workflows/ directory, I can't seem to get a solid ...
0
votes
0
answers
68
views
Error: Cannot find module '@/libs/shared/middlewares/error.middleware' in Dockerized pnpm Monorepo
I'm working on a MERN monorepo using pnpm workspaces and trying to dockerize the entire setup using Docker Compose. The application runs perfectly without Docker but it breaks when I start docker ...
0
votes
1
answer
123
views
Error: Could not resolve various Storybook dependencies with Storybook 8 and PNPM
When attempting to use Storybook 8 with PNPM in my Next.js project, I encounter errors indicating that various Storybook dependencies cannot be resolved. This issue persists despite multiple ...
0
votes
0
answers
28
views
pnpm align dependency versions across packages in monorepo
I'm building an extension for Prisma, and I've put two workspaces into a monorepo, one for the package itself, and one for development testing:
/package.json
/pnpm-workspace.yaml
/package/package.json
...
0
votes
1
answer
55
views
setup-node pnpm node_modules location
I'm still having this problem, which is fine in development — I just manually create a symlink in the top-level node_modules. However, I'm now trying to integrate linting into my GitHub CI actions, ...
0
votes
0
answers
117
views
Why does pnpm inconsistently display the list of deprecated subdependencies on install?
In one of the repos I use regularly, when running pnpm install (or pnpm install --resolution-only), it displays a warning about deprecated subdependencies, e.g.,
WARN 6 deprecated subdependencies ...
2
votes
2
answers
94
views
Start-Process (pnpm run build) This command cannot be run due to the error: %1 is not a valid Win32 application
I have the next ps1 file created:
$Tool="pnpm"
$ArgumentList="run", "build"
$processResult = Start-Process `
-FilePath $Tool `
-ArgumentList $...
0
votes
0
answers
122
views
The "fileName" or "name" properties of emitted chunks and assets must be strings that are neither absolute nor relative paths
what i am using: vue3, pnpm, vite
PROBLEM: i have a pnpm workspace and there is two folder for workspaces, packages which contain a project called "shared" for common stuff, and a folder ...
0
votes
1
answer
29
views
globals package "hoisted" but not linked in pnpm?
I have a pnpm monorepo (multiple workspaces). In one of the workspaces, I need to use the globals package, so that ESLint 9 can be made aware of native Node globals (e.g., process). What I end up with ...