I have an Angular web app and bunch of classes with double dashes in names (e.g. --loaded
or --primary
). Once I build my application, the such classes are not escaped with backslashes which causes problems in IE11 and Edge 14.
For example, such SCSS code
.graph-placeholder
opacity: 0
transition: 0.2s opacity
&.--loaded
opacity: 1
is compiled to this
.graph-placeholder.--loaded {
opacity: 1;
}
instead of
.graph-placeholder.\--loaded {
opacity: 1;
}
This is handled by Chrome or Edge 16 but not IE11 or older versions Edge.
How can I make Angular CLI to compile SCSS files correctly?
Package versions:
@angular/animations@5.2.1
@angular/cli@1.7.3
@angular/common@5.2.1
@angular/compiler@5.2.1
@angular/compiler-cli@5.2.1
@angular/core@5.2.1
@angular/forms@5.2.1
@angular/http@5.2.1
@angular/platform-browser@5.2.1
@angular/platform-browser-dynamic@5.2.1
@angular/platform-server@5.2.1
@angular/router@5.2.1
typescript@2.6.2