Closed parliament718 closed 3 years ago
Hmm seems to be a general issue with compatibility between angular and mini css extract plugin... See for example https://github.com/webpack-contrib/mini-css-extract-plugin/issues/186
Thanks that helped me resolve it.
I was aware of that issue and I was already following that approach of importing scss files directly in the TS file instead of using styleUrls
on components.
In my Angular library (separately in /projects folder), I still use styleUrls
since the library gets compiled separately and imported from the compiled code in node_modules (via npm link)
The oversight was that VScode put an automatic import from "projects/mylib/..."
instead of import from 'mylib'
and that caused source files with styleUrls
to get inadvertantly imported.
Changing that one instance to import from 'mylib'
solved the issue.
I'm not able to compile my app with
electron-webpack dev
anymore. The compilation error is as follows (I get one of these errors for just about every scss file in my library):My
webpack.renderer.additions.js
doesnt have much, so mostly using defaults. This configuration was working for me for a long time. I'm not sure what changed. I recently upgraded from Angular 10 to 11, but I have since been able to compile successfully. Now all of a sudden Im getting that error.webpack.renderer.additions.js
: