I have a pnpm workspace with the following structure:
root
|- example
| |- package.json
|
|- packages
| |- a
| | |- package.json
| |
| |- b
| | |- package.json
| |
| |- c
| | |- package.json
The package c is a package that should contain a and b:
{
"name": "c",
"dependencies": {
"a": "workspace:*",
"b": "workspace:*"
}
}
package.json file in example looks like this:
{
"name": "example",
"dependencies": {
"c": "workspace:*"
}
}
When I do pnpm install it places only c dependency in example/node_modules - it does not install necessary packages a and b.
What do I have to do to have all nested dependencies installed correctly?
They are installed correctly. The
cinsideroot/example/node_modulesis a symlink toroot/packages/c. The dependencies ofcare symlinked toroot/packages/c/node_modules.