Closed yuri-scarbaci-lenio closed 4 years ago
As an additional source of the problem I will link this medium article where an alternate solution is given, but the alternate solution actually remove all the css chunking
magic from the process and I would strongly not recommend doing it to solve the problem with 'css modules' since by nature they should not depend on a given order of css import.
@yuri-scarbaci-lenio Thanks, I think it makes sense.
Maybe add miniCssExtractOptions on this line and spread the options on this line so we can configure the mini-css-extract plugin ourself in a similar fashion as we do with the other plugins?
Yeah, why not. I am open if you provide a PR for this
@webdeb Created the PR and tested it against my local project, works as expected.
I took the freedom to
README.md
file to reflect the change and explain how to easly contribuite to this repositorynpm audit
problemsCHANGELOG.md
file to keep tracks of the changes
First of all thanks a lot for the plugin!
I'm facing an issue where the build process goes a little bombastick about not being able to get a definitive order of the imported scss, I suspect due to the nature of how next.js handles the building process...
I do understand that getting a working configuration that doesn't throw the warning left and right will be almost impossible since it's deeply tied to next.js and it's not even worth given how subject to change it is, but what would be really nice is the ability to configure the mini-css-extract-plugin to pass the ignoreOrder flag...
I'm especially referring to this issue with mini-css-extract
Maybe add
miniCssExtractOptions
on this line and spread the options on this line so we can configure the mini-css-extract plugin ourself in a similar fashion as we do with the other plugins?also by nature I think that if css/sass modules are enabled and we are getting pretty much scoped css anyway, we would want to default the option of ignoring the order to true by default?
P.S. this is an example of the error I'm getting:
this is not only annoying, this would prevent configuring CI & CD pipelines that fails on warning...