You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I suggest adopting a Lerna monorepo style for this. This is what I've done for the js-debug profilers (though the build is somewhat convoluted in there due to having multiple client/webview and extension host build targets...) which lets me just run lerna version patch to publish and update all packages. This will also enable us to automate publishing more easily 🙂
The main reason for the wait is that the package-lock.json in the second packages needs to be updated with the new version. Well, doesn't have to be, but if it isn't then npm installing will create a dirty workspace, which is messy. Lerna will symlinks the packages locally, so that issue is resolved. npm doesn't actually enforce dependency versions on publish, so Lerna can just publish all relevant package versions simultaneously.
Activity
roblourens commentedon Feb 8, 2022
How does lerna help you deal with having to wait for one package to be available in npm before you can update the dependency in another project?
connor4312 commentedon Feb 8, 2022
The main reason for the wait is that the package-lock.json in the second packages needs to be updated with the new version. Well, doesn't have to be, but if it isn't then npm installing will create a dirty workspace, which is messy. Lerna will symlinks the packages locally, so that issue is resolved. npm doesn't actually enforce dependency versions on publish, so Lerna can just publish all relevant package versions simultaneously.
roblourens commentedon Feb 8, 2022
Does that mean that package A that depends on B, contains package B when published?
connor4312 commentedon Feb 8, 2022
No, it can still reference package B as its own separate npm package.
refactor: adopt monorepo structure
refactor: adopt monorepo structure
refactor: adopt monorepo structure
refactor: adopt monorepo structure
refactor: adopt monorepo structure
weinand commentedon Mar 2, 2022
Connor Peet (@connor4312) great idea to improve this (although I never had to "wait" for the protocol publish to propagate...)
add webpack browser support
Fix capitalization of GitHub org