Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

node-sass and includePaths #55

Open
ctrlmaniac opened this issue Jun 19, 2018 · 1 comment
Open

node-sass and includePaths #55

ctrlmaniac opened this issue Jun 19, 2018 · 1 comment

Comments

@ctrlmaniac
Copy link

Hi, it would be awesome to support node-sass includePaths feature with this project!
In my fork I've made some changes in order to support it! I'm not pushing a request because I don't use compass, bower nor diamonds so I don't know how this affects those but I've tested it on my sass project, which uses grunt-sass (so node-sass) and it works flawlessly, it just has to be tested with other supported tools!

To support the includePaths it's pretty simple: just create a index.js file where you will export the path to the scss folder:

var path = require( "path" );

module.exports = {
  includePaths: [
    path.join( __dirname, "scss" )
  ]
};

and then in the package.json file just change the main file to index.js

In this way, I can easily install this plugin with npm and require the file in my gulp, grunt or pure node file.

Then In my scss file I just have to @import typi;

That's pretty simple!

I'm asking this because in this way code is much more mantainable! No copy-paste required!

@zellwk
Copy link
Owner

zellwk commented Jun 20, 2018

Thank you for the suggestion, @dcdeiv. Do you mind sending a PR? That'll help me push the changes much faster.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants