-
-
Notifications
You must be signed in to change notification settings - Fork 429
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
Error after migrating from v4.1.1 to v6.0.2 #393
Comments
With further debugging I realized that the problem is with node-sass ^4.0.0. I believe is something to do with the :property_syntax option from Sass. From the docs:
So, as I'm using local scoped class names from css-loader Any ideas on how I can fix this? For now, I'm just keeping ^3.0.0 from node-sass, but its not a solution as I always get an index.sass
node-sass ^3.0.0 import sass from 'node-sass';
const result = sass.renderSync({ file: './index.sass' });
console.log(result);
/*
{
stats:
{
entry: './index.sass',
start: 1488802011040,
includedFiles: [ './index.sass' ],
end: 1488802011047,
duration: 7,
},
css: <Buffer 3a 6c 6f 63 61 6c 28 2e ... >
}
*/ node-sass ^4.0.0 import sass from 'node-sass';
const result = sass.renderSync({ file: './index.sass' });
/*
Error: Invalid CSS after "l": expected 1 selector or at-rule, was "local(.container): "
at Object.module.exports.renderSync (./node_modules/node-sass/lib/index.js:439:16)
at repl:1:19
at ContextifyScript.Script.runInThisContext (vm.js:23:33)
at REPLServer.defaultEval (repl.js:336:29)
at bound (domain.js:280:14)
at REPLServer.runBound [as eval] (domain.js:293:12)
at REPLServer.onLine (repl.js:533:10)
at emitOne (events.js:101:20)
at REPLServer.emit (events.js:191:7)
at REPLServer.Interface._onLine (readline.js:238:10)
*/ |
The \:local(.container)
padding-top: 20px |
Thank you very much, @jhnns. Priceless help. |
Thanks @jhnns! Already spent a lot more time on this issue than I hoped, but I'm pretty sure your post saved me from spending a lot lot more ;) |
Sass-loader version: from 4.1.1 to 6.0.2
Node-sass version: from 3.13.1 to 4.5.0
After updating the packages, the project that I'm working on is not building anymore. I believe the problem is related to the fact that my .css files are configured to make the class names scoped locally. (:local). I'm literally researching for this problem for 3 hours, and if I downgrade to the previous version that I had installed before, everything works again. Could anyone shed some light on this subject?
index.sass
webpack.config.js
ERROR
The text was updated successfully, but these errors were encountered: