[Q] use absolute paths to import sass files
See original GitHub issueIs there a way to use absolute paths for sass imports? For example, when trying to import src/shared/variables.scss
from a deeply nested component, there could be a lot of ../../../../
to import the right style file.
Related: #1712 (for importing JS files)
Issue Analytics
- State:
- Created 6 years ago
- Comments:5 (4 by maintainers)
Top Results From Across the Web
css - How to use absolute path to import custom scss, when ...
Let's say I'm creating an MyAdminButton and I want to import scss file that concerns all the buttons of the project. (It's custom...
Read more >Sass: @import
All Sass implementations allow users to provide load paths: paths on the filesystem that Sass will look in when resolving imports. For example,...
Read more >absolute path - npm search
A node-sass custom importer which turns ~ into absolute paths to the nearest parent node_modules directory. node-sass · scss · sass · tilde...
Read more >CSS : How to use absolute path to import custom scss, when ...
CSS : How to use absolute path to import custom scss, when using react + webpack?
Read more >sass-loader - webpack - JS.ORG
Resolving import at-rules ... Webpack provides an advanced mechanism to resolve files. The sass-loader uses Sass's custom importer feature to pass all queries...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop 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
Top GitHub Comments
fuller example:
"css:build": "node-sass-chokidar --include-path ./node_modules/foundation-sites/scss --include-path ./src --include-path ./node_modules src/ -o src/",
@kellyrmilligan thanks! this is perfect. Please feel free to close the issue 😃