CSS Loader Invalid Options Error #392
Comments
|
+1. this error happend from css-loader 2.0.0 |
|
dont update to css-loader to v2. Inside using v1 |
|
|
|
Also got this error while using |
|
@sergaunt please create minimum reproducible test repo, thanks! |
|
I also got this error while using |
|
@szpasztor if you comment out |
This comment has been minimized.
This comment has been minimized.
|
I can confirm that hack is not needed with |
|
i used the hack. sorted it right out. cheers. |
|
I don't even have minimize option but still get the same error 😕 |
|
Installing packages via yarn solved the problem. What the heck? 🤯 |
|
npm cache |
|
@evilebottnawi that was a fresh install. So I don't think that the problem is in cache |
|
I ran into the same issue with |
|
@jnv Even when installing
Using next.config.js I'm trying to get Ant Design styles written in Less to be correctly imported, but to no avail. 😫 |
|
Same is with next-sass, loader needs fixing or updating. |
|
Yep, I tried |
|
The solution from @marcusstenbeck works, but I could not find minimize option inside css-loader in node_modules, or it is inside some other package... |
|
I had this issue... EDIT: I was wrong! Still broken, my yarn just didn't get the latest |
|
@andezzat Share your config/setup, because using the "latest" versions does not fix anything. I've tried with all three packages and get the same result. You're getting different results than the rest of us. "@zeit/next-css": "^1.0.1",
"@zeit/next-less": "^1.0.1",
"@zeit/next-sass": "^1.0.1",
...
"next": "^9.0.7",// next.config.js
const withCSS = require('@zeit/next-css')
module.exports = withCSS() |
|
@KnightYoshi Apologies, you're right! I'm pretty sure it only realised it needs I'm going to investigate why this |
|
Ok... so here's what I know so far
What I reckon is causing this issue in That's as far as I have time to look into this... |
|
next @9.0.6 does not have the issue either. |
|
@wulfmann 9.0.5—9.0.7 all have the same issue. I started on 9.0.5 and upgraded to 9.0.6 and then 9.0.7. All of which generate the same CSS loader invalid config issue. It's an issue with the plugins, not Next itself. |
|
As per my dissection comment above: please try installing |
|
@andezzat Still failing for me. |
|
I can confirm using |
|
Thanks @andezzat Using |
|
@andezzat Correction, I didn't upgrade If I upgrade to No idea where this comes from, since there's no stack trace. It's odd, since my code doesn't reference |
This comment has been minimized.
This comment has been minimized.
|
This has been fixed in |
|
@Timer sure! But shouldn't breaking changes like these be part of stable releases so people don't run around in circles like they did in this thread trying to figure out what's broken? |
|
Next 9.0.7 is broken. It needs to be fixed. |
|
@orourkea2017
It already is fixed. Just pending stable release. Please try it out. |
|
A timeframe @timneutkens?? A bugfix is no use in beta. |
|
The way you're communicating is kind of weird. But we don't release on weekends and no one communicated back that it works so we were waiting a bit to see if other issues pop up. |
|
Okay, thank you. I apologise if I come across as strange - that was not my intention, although I know I am blunt at times. Sorry. I also did not realise it was a weekend - I am in Australia, and while we are on a weekend, I always think that everyone else is miles behind us time-wise. Again, sorry. I take it we can expect this to be stable in a few days. Thank you, much appreciated. |
When loading in a CSS file from
node_modulesusing thenext.config.jsfile here, the following error is generated on compile:In referencing the suggestion from @truonghoangphuc here, I commented out
minimize: !dev,incss-loader-config.jsinnode_modules/@zeit/next-css/css-loader-config.jsI've confirmed that commenting that line out makes CSS loading work again and the errors go away.
The text was updated successfully, but these errors were encountered: