question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Include `src/` path for sass-loader

See original GitHub issue

Would it be more convenient to add src/ to the includePaths of the SASS loader?

So we can include files in a separate path without counting how many ‘…/’ we should have.

@import 'scss/base/buttons.scss';

Rather than:

@import '../../../scss/base/buttons.scss';

Issue Analytics

  • State:open
  • Created 7 years ago
  • Reactions:2
  • Comments:6 (1 by maintainers)

github_iconTop GitHub Comments

1reaction
golinmarqcommented, Apr 20, 2017

@kitze what happen with this?

0reactions
devxpycommented, Jun 7, 2018

^Nice, can we also incorporate for the NODE_PATH env, like @willhackett said?

Read more comments on GitHub >

github_iconTop Results From Across the Web

Webpack sass loader resolve absolute path - Stack Overflow
In your Scss/SASS on import use ~ ahead file path. ... that resolves relative paths in url() statements based on the original source...
Read more >
sass-loader - webpack - JS.ORG
The loader will first try to resolve @import as a relative path. If it cannot be resolved, then the loader will try to...
Read more >
sass-loader can't resolve path to _index.scss file when using ...
Currently it only works for relative imports and fails when I try to import _index.scss using an alias in my import path. Expected...
Read more >
Sass with Webpack - LearnHowToProgram.com
First we'll create a sass folder in our src directory with a styles.scss file inside. For now it'll contain basic Sass to style...
Read more >
webpack: provide support for sass-loader `includePath` property
In my webpack config I have this: { loader: 'sass-loader', options: { sourceMap: true, includePaths: [path.resolve('./src/js/components')], outFile: 'xx' }
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found