Remove icons and non required fonts

I am trying to do a bit of a tidy up and remove files I do not use. I have been following (without success!)

Basically his advice is to remove the icons and non required fonts from src/theme/variables.scss which I have followed (see below) both icons and noto-sans fonts commented out.

// Ionicons
// --------------------------------------------------
// The premium icon font for Ionic. For more info, please see:

// @import “ionic.ionicons”;

// Fonts
// --------------------------------------------------

@import “roboto”;
// @import “noto-sans”;

However when I preform a release build and look at the output file - the icons and fonts are still in the assets folder.

Has anyone got any suggestions?

1 Like

Ionic v4 does this automatically - one of the features I find most exciting. It only imports what you explicitly ask for. So you might want to try running your app under v4 and see if it works.

1 Like

Thanks - but V4 is not yet ready for production (or at least that is my understanding) - I have been waiting and waiting for version 4 - must be over 4 months now!

Take a look at:

And, create your own copy.config.js:

module.exports = {
  copyAssets: {
    src: ['{{SRC}}/assets/**/*'],
    dest: '{{WWW}}/assets'
  copyIndexContent: {
    src: ['{{SRC}}/index.html', '{{SRC}}/manifest.json'],
    dest: '{{WWW}}'
  copyFonts: {
    src: ['{{ROOT}}/node_modules/ionic-angular/fonts/noto-sans**',
    dest: '{{WWW}}/assets/fonts'
  copyPolyfills: {
    src: [`{{ROOT}}/node_modules/ionic-angular/polyfills/${process.env.IONIC_POLYFILL_FILE_NAME}`],
    dest: '{{BUILD}}'
  copySwToolbox: {
    src: ['{{ROOT}}/node_modules/sw-toolbox/sw-toolbox.js'],
    dest: '{{BUILD}}'


THanks @robinyo I will work through instructions later today and see what effect it has.