I've recently migrated a large JS project to a JS monorepo. I've updated the package.json file in each of the packages to use the same version for hoisting.
rwxr-xr-x - mridang 21 Jan 12:51 ├── packages
drwxr-xr-x - mridang 21 Jan 14:30 │ ├── admin-customer-import
drwxr-xr-x - mridang 21 Jan 14:30 │ ├── admin-tools
drwxr-xr-x - mridang 21 Jan 14:30 │ ├── mycommoncode
Both admin-customer-import
and admin-tools
have these in the dependencies:
"dependencies": {
"axios": "^0.21.1",
"save": "^2.4.0",
"mycommoncode": "*",
"vue": "^2.6.12",
"vue-router": "^3.4.9",
"vuex": "^3.6.0"
}
When I run npx lerna bootstrap --hoist
- it completes successfully but then only creates symlinks for the mycommoncode
shared package inside the respective node_modules
folder.
If I run npx lerna boostrap
- it installs the same dependencies (not symlinks) in each of the node_modules
directories.
What am I doing wrong? I've been through the docs but I cannot get the deps symlinked.
from Why doesn't Lerna symlink my dependencies?
No comments:
Post a Comment