Closed russaa closed 3 months ago
+1
Or please add a migration guid
+1
fyi if anyone else is wondering:
the configuration
option is now part of the ionic
CLI itself.
So instead of
# previously/outdated:
ionic build -- --configuration=my_configuration
you would use
# new:
ionic build --configuration=my_configuration
(i.e. use it before/without the double hyphen)
Description: starting with Angular 14.x the Angular CLI
ng run
does not support the--configuration
option any more, see Angular 14.0.0 Release Notes:(and discussion in issue https://github.com/angular/angular-cli/issues/23385)
As a consequence, Angular configuration targets cannot be specified via the Ionic CLI command
ionic build
any more:in Angular 13.x it was possible to specify a configuration with
which would generate the command
_(NOTE:
my_configuration
is just an example, that isangular.json
would need to contain a configuration formy_configuration
- to use an existing configuration that exists by default for Ionic apps you could use the configuration forproduction
)_in Angular 14.x this generated command produces an error
One possible solution would be, that the Ionic CLI parses the
--configuration
option and appends it to the generatedng run
target, i.e. forionic build -- --configuration=my_configuration
generate something likeSteps to Reproduce:
test by explicitly setting
production
configuration in Ionic CLI options:ionic build -- --configuration=production
Output:
My
ionic info
:Other Information:
my need to use
npm shrinkwrap
to patch the angular version(s) used by@ionic/cordova-builders
to use angular 14