Description:
In an Ionic v4 app, when building it with the cli v4, all ionicons will be integrated in the bundle regardless of their use or not which leads to a too big app size
When I run ionic cordova build android --prod --release the app-release.apk will contains a folder www/svg with all ionicons
Steps to Reproduce:
ionic start test-icons --type=angular
cd test-icons
ionic cordova build android --prod
cd platforms/android/app/build/outputs/apk/debug/
unzip app-debug.apk
cd assets/www/svg/
ls -ltr
or
which will count 697 icons
Output:

My ionic info:
Ionic:
ionic (Ionic CLI) : 4.0.3 (/usr/local/lib/node_modules/ionic)
Ionic Framework : @ionic/angular 4.0.0-beta.3
@angular-devkit/core : 0.7.3
@angular-devkit/schematics : 0.7.3
@angular/cli : 6.1.3
@ionic/ng-toolkit : 1.0.6
@ionic/schematics-angular : 1.0.5
Cordova:
cordova (Cordova CLI) : 8.0.0
Cordova Platforms : android 7.0.0
System:
Android SDK Tools : 26.1.1
ios-deploy : 1.9.2
ios-sim : 5.0.13
NodeJS : v10.4.0 (/usr/local/bin/node)
npm : 6.2.0
OS : macOS High Sierra
Xcode : Xcode 9.4.1 Build version 9F2000
Description:
In an Ionic v4 app, when building it with the cli v4, all ionicons will be integrated in the bundle regardless of their use or not which leads to a too big app size
When I run
ionic cordova build android --prod --releasetheapp-release.apkwill contains a folderwww/svgwith all ioniconsSteps to Reproduce:
or
which will count 697 icons
Output:
My
ionic info: