I want to apply dynamically SCSS styling according to a variable, known prior to Angular bootstrapping. Is it possible to change styles.scss programmatically? In main.ts before bootstrapping, I want to add dynamically a line like:
@import 'assets/styles/customerA/_themes.scss';
or
@import 'assets/styles/customerB/_themes.scss';
depending on a variable's value coming from the server.
If the above is not feasible, is there any way to populate styles.scss with the content of another file which will be defined on the server? I want to change styles.scss and not any other "local" scss file.
from Change styles.scss dynamically in Angular
No comments:
Post a Comment