CSS compiling issue - Ionic 4

Hi all,

I have been having an issue I think is to do with the CSS compiling. I am only getting this problem when building for production - it works fine on local.

This may be to do with the asset pipeline, or Ionic trying to be a bit clever when compiling.

I have found that on a production build CSS can be stripped out / ignored. In particular this seems to happen when there is a component within a component with unique CSS related to the child component being (that is only needed IF the component is a child as both components can work individually) This CSS when declared wrapped in a class relating to the parent will just not compile.

The only work around I have found is to add this type of CSS to my base.scss which is not a great way of working as its getting messy.

On a related issue - I also had problems trying to include a CSS file with unique styles on a specific page - unless part of this included file is referenced in the page’s CSS it will also not compile - but only on production. Works fine on local.

I am new to Ionic - is there something I am doing wrong in the layout of my styles, or is this an issue anyone else is having with the Ionic 4 beta?

Thanks
Chris