Closed
Description
Bug Report
Angular CLI allows us to add Schematics for default ChangeDetectionStrategy
Ionic should allow for that as well. Default change detection strategy is a performance hit so i want to default to OnPush.
This setting should be looked at both when generating "Page" and "Component".
Ionic version:
[ ] 4.x
[x] 5.x
Steps to reproduce:
npx ionic g page test-page
npx ionic g c test-component
Check the generated code and see no ChangeDetectionStrategy.OnPush
Ionic info:
Ionic:
Ionic CLI : 6.11.8
Ionic Framework : @ionic/angular 5.3.3
@angular-devkit/build-angular : 0.1001.2
@angular-devkit/schematics : 10.1.2
@angular/cli : 10.1.2
@ionic/angular-toolkit : 2.3.3
Cordova:
Cordova CLI : 7.0.1
Cordova Platforms : none
Cordova Plugins : no whitelisted plugins (3 plugins total)
Utility:
cordova-res : 0.15.1
native-run : not installed
System:
Android SDK Tools : 26.1.1 (/Users/mluz/Library/Android/sdk)
ios-deploy : 1.9.1
ios-sim : 6.0.0
NodeJS : v14.11.0 (/Users/mluz/.nvm/versions/node/v14.11.0/bin/node)
npm : 6.14.8
OS : macOS Catalina
Xcode : Xcode 11.3.1 Build version 11C504
Activity
liamdebeasi commentedon Sep 23, 2020
Thanks for the issue. I am going to close this as a duplicate of ionic-team/angular-toolkit#94.
ionitron-bot commentedon Oct 23, 2020
Thanks for the issue! This issue is being locked to prevent comments that are not relevant to the original issue. If this is still an issue with the latest version of Ionic, please create a new issue and ensure the template is fully filled out.