Ionic 4 to 5 help

Hi
I am trying to upgrade my Ionic 4 project to 5, but have some issues. I have made sure my app works with version 4.11.10 first.

This is my current setup.

G:\AVR_Project\Ionic Projects\app>ionic info

Ionic:

   Ionic CLI                     : 5.4.16
   Ionic Framework               : @ionic/angular 5.0.5
   @angular-devkit/build-angular : 0.13.9
   @angular-devkit/schematics    : 7.2.4
   @angular/cli                  : 7.2.4
   @ionic/angular-toolkit        : 2.2.0

Cordova:

   Cordova CLI       : 9.0.0 (cordova-lib@9.0.1)
   Cordova Platforms : android 7.1.4, ios 5.0.1
   Cordova Plugins   : cordova-plugin-ionic-keyboard 2.1.3, cordova-plugin-ionic-webview 4.1.0, (and 13 other plugins)

Utility:

   cordova-res : 0.8.0
   native-run  : 0.3.0

System:

   NodeJS : v10.15.3 (C:\Program Files\nodejs\node.exe)
   npm    : 6.4.1
   OS     : Windows 7

I am getting various warning and errors. But before i start mentioning them…

If i am correct in saying i need upgrade the angular to version 9? How do i do that?

Is there any user guide that i can follow ?

Thanks

https://www.google.com/search?q=angular+9+upgrade+guide

Thanks i got it working,

I can see it working with ionic serve, but when i try to preform a ionic cordova run android I get the following error

An unhandled exception occurred: architect_1.createBuilder is not a function
See “C:\Users\DJ\AppData\Local\Temp\ng-baL6EH\angular-errors.log” for further details.
[ERROR] An error occurred while running subprocess ng.

    ng.cmd run app:ionic-cordova-build --platform=android exited with exit code 127.

https://www.google.com/search?q=architect_1.createBuilder+is+not+a+function

Are you starting to see a pattern here yet?

What pattern is this?

Seems like angular 9 is giving me issues

Hi there! From the sounds of things, you have these deps in your package.json.

    "@angular-devkit/architect": "~0.801.2",
    "@angular-devkit/build-angular": "~0.803.0-next.1",
    "@angular-devkit/core": "~8.1.2",
    "@angular-devkit/schematics": "~8.1.2",

You edit this to just have

 "@angular-devkit/build-angular": "~0.900.6"

Then delete node_modules and your package-lock, and install things again. The other packages that have been removed are now listed as deps of build-angular and should managed by that.

Hi

This is what i have:

    "@angular-devkit/architect": "^0.12.4",
    "@angular-devkit/build-angular": "~0.900.6",
    "@angular-devkit/core": "^9.0.6",
    "@angular-devkit/schematics": "^9.0.6",

So do i just keep “@angular-devkit/build-angular”: “~0.900.6”, and delete the other three?

Do i simple delete node_modules and your package-lock from Visual Studio code? How do i then re generate them again?

Yes, remove @angular-devkit/architect, @angular-devkit/core, @angular-devkit/schematics from package.json

Delete node_module and package-lock

Then run npm install from the command-line in your project.

I have done all that but i get the following error now/

ionic cordova run android
> ng.cmd run app:ionic-cordova-build --platform=android
An unhandled exception occurred: Cannot find module '@angular-devkit/architect'
See "C:\Users\DJ\AppData\Local\Temp\ng-0FczmQ\angular-errors.log" for further details.
[ERROR] An error occurred while running subprocess ng.

        ng.cmd run app:ionic-cordova-build --platform=android exited with exit code 127.

        Re-running this command with the --verbose flag may provide more information.

Is there a reason why i am a get this error now?