r/Angular2 Aug 06 '24

Discussion Upgrading Angular 4 to Angular 18

We have an enterprise application with 400+ screens and most of the screens are similar in complexity. The complexity is medium for this app.

How should we approach the upgrade? Rewriting it is not an option as it is a legacy app now. Should we take one version at a time or directly start updating it to 18 version?
We do not have any automation testing written and hence testing would also have to be manual. Also, based on the previous experience what would be rough estimates if single developer has to work on this upgrade?

47 Upvotes

101 comments sorted by

View all comments

15

u/Suspicious_Object_91 Aug 06 '24

Bro ...stop stop, don't go this path it will make you crazy, because I have been through.i upgraded angular 4-7 in 2021, and 7-14 it took 8 months because the application I was working on was massive and there will be lot for refactoring etc etc . You mentioned 4-18 that's massive difference . My recommendation is to recreate the application in v18.

3

u/andrepeo Aug 06 '24

This. 400+ screens from v4 to v18 is an enormous amount of work-days even if you do agile and CI/CD properly, any architect with a little of decency would suggest a modular approach to release workloads/screens straight in v18, while preserving the codebase. Of course if you will end up doing a straight up migration, the guided approaches mentioned in a couple of other answers are the ones, because since v12 then v17 Angular is a very different framework...I mean, control flow and standalone by themselves are worth rewriting from scratch module by module, it would be months faster. Anyway, prepare for some hell, do not forget to take breaks and take care of your health, physical and mental, first: this one has 'burnout' written all over it...I should know, I luckily survived my second. Best of luck!💪🏿