- Sponsor
-
Notifications
You must be signed in to change notification settings - Fork 65
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
Possibly not just sass-resource-loader #31
Comments
@alexfedoseev This is a good idea. I suggest we change the repo name to resources-loader. I reserved https://www.npmjs.com/package/resources-loader. |
I guess make sense, tho it requires some investigation and testing before changing-all-the-things. Also, Post-CSS handles it way better as it uses js files for this, so it's possible to share variables w/ JS modules, so I wouldn't suggest it for Post-CSS users. |
I see how the name is confusing. Probably README should explain clearer what it does. The only thing it does is that it transforms sass syntax into css using some set of resources as additional files. So the |
@Vanuan I wouldn't change the name unless we have tests for |
I'm posting in case anyone else is trying to get this to work with stuff besides sass, or wasn't sure if it would actually work. I was using Nuxt and extend(config, ctx) {
// sass-resource-loader goes right after (array positioning)
let sassResourceLoader = {
loader: 'sass-resources-loader',
options: {
resources: path.join(__dirname, 'assets/open-color.css')
}
}
// 6 corresponds to the test for /\.p(ost)?css$/i
let css = config.module.rules[6]
css.oneOf.forEach(item => {
item.use.push(sassResourceLoader);
})
} |
I suggest you rename this with [sass|post-css|less|whatever]-resources-loader instead of sass-resources-loader. I am using this with post-css and it works as intended, I had to read your code to give me a hope to try it :), I guess your title would put off many people like me.
The text was updated successfully, but these errors were encountered: