1
votes

I want to upgrade my angular app from 6.1 to 8.0. My setup has lerna and yarn workspace. I want to upgrade each package in the repo. When I follow the update instruction on https://update.angular.io/ I doesn't update the sub packages . I tried to search about this problem but I haven't found a solution.

I run "ng update @angular/core @angular/cli" but I just managed to update the main package.json packages but when I check the sub packages they are still on angular 6.1. I have also tried this https://www.npmjs.com/package/lerna-update-wizard to update but it still fail.

If anyone has this situation before I would appreciate the help. Thanks

1

1 Answers

0
votes

I found an answer, if you have a setup of packages as a monorepo, you would need to use a package to update each angular application package.json.

I used https://www.npmjs.com/package/npm-check-updates.

run lerna exec "npx npm-check-updates -u '/^(@angular).*$/'" to upgrade only angular packages to latest. this /^(@angular).*$/ means select only angular applications.