stylePreprocessorOptions loads node_modules instead of scss
See original GitHub issueUsing @import 'file'
imports from node_modules when the file is named the same way any node module is named.
Angular.json
"stylePreprocessorOptions": {
"includePaths": [
"src/styles"
]
},
Existing files
src
- styles
- _globals.scss
- _rxjs.scss
my-component.scss
@import 'globals';
-> Imports node-module “globals” index.js
my-component.scss
@import 'rxjs';
-> Imports node-module “rxjs” index.js
Version @angular/cli: 6.0.0-rc.7
Issue Analytics
- State:
- Created 5 years ago
- Reactions:7
- Comments:20
Top Results From Across the Web
angular.json includePaths is not workings for node_modules
1 Answer 1 · How to reference external node_modules css? I use Angular library which contains component using external css: @import " ...
Read more >systelab-components - npm
After, you must add the following styles, stylePreprocessorOptions and scripts in the angular.json file,. "styles": [ "node_modules/ag-grid- ...
Read more >Using Pre-Processors - Vue Loader
Any content inside the block will be processed by webpack as if it's inside a *.scss file. # Sass vs SCSS. Note that...
Read more >SASS "includePaths" in angular.json is not recognized when ...
I have an Angular monorepo project. I've set projects.public.architect.build.options.stylePreprocessorOptions.includePaths to be ["projects/public/src/ ...
Read more >How to use SCSS mixins with angular 7? - GeeksforGeeks
scss " ], "stylePreprocessorOptions": { "includePaths": [ "../node_modules/bootstrap/scss" ] },. Using Bootstrap Sass Files: Another scenario we' ...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
This also happens if file name is ‘colors’
If anyone finds this in the short future, until the commits above are merged. I am on:
Downgrading sass-loader in
package.json
fixed this issue for me.