Reputation: 1015
I have a hybrid AngularJS (1.7.0) and Angular 6 app. I am also using @angular/upgrade module to upgrade/downgrade components and services. I have got it working using custom webpack but now I want move towards angular-cli.
Can anyone suggest the best approach to do that.
I am thinking :-
Move Angular 6 to Angular Cli and build AngularJS using custom webpack. But I am not sure what will happen when we navigate between the upgraded/downgraded components.
Upvotes: 0
Views: 791
Reputation: 6234
angular-cli
hides webpack configuration by default (which you can access by using the eject
command).
Switching from your configuration to the angular-cli
is not trivial if you heavily customized webpack.
We migrated several projects via ngUpgrade and component marshalling between angular and angularjs didn't break.
We had several issues in traslating all the heavy-configured webpack tasks. In the end, we successfully migrated all the projects by creating brand new projects with angular-cli
and importing only our code, this approach had these pros:
It took some time to incrementally plug the code, but once the skeleton was working, the task became straightforward. This approach builds both angular and angularjs with the same typescript compiler, without webpack.
Upvotes: 2