-
Notifications
You must be signed in to change notification settings - Fork 156
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
Using PostCSS mixins in CSS modules causes a syntax error #424
Comments
Hi @sevilyilmaz I transfered the issue to vue-jest as I indeed think this is a a vue-jest issue. If you want to give a hand, you can try to add a test to this repo and see what syntax is failing specifically. Maybe we can use another dependency to do this job instead of |
@cexbrayat vue-jest does not have unit tests. Adding my example in one of the fixtures in E2E tests resulted the same error with less details.
I dug into it a bit and this is what I found. We can use What do you think? |
That would probably be way better, if you would like to make a PR, that would be awesome! |
I picked an another route and replaced the CSS parser. Please have a look. |
Replaced `extract-from-css` which is outdated (7yo) with `css-tree` Resolves #424
This issue might be related to
vue-jest
but I'll open it here because I got the error from the test utils and I'm 100% sure of the what is responsible from it. Please feel free to point me to the correct repo if this is not the one.Description
I get the error below when I use a PostCSS mixin in a CSS file. I assume it expects a semicolon where I use the mixin while parsing the CSS file but it cannot find it and throws this error.
Reproduction link: https://github.com/sevilyilmaz/vue-3-setup-css-modules-mixin
Setup
HelloWorld.vue
HelloWorld.module.css
HelloWorld.test.js
jest.config.js
The text was updated successfully, but these errors were encountered: