-
-
Notifications
You must be signed in to change notification settings - Fork 196
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
The new svelte-check can't deal with Tailwindcss's new experimental applyComplexClasses feature #484
Comments
Looking at the template, the problem is that inside We also have some short docs on TailwindCSS, yeah are welcome to enhance them if my suggestions work out for you. |
It what you're saying is correct, then wouldn't you expect that any Svelte component that contains an I'm still gonna try what you're proposing, I'm just a bit skeptical about your reasoning. :-) edit@dummdidumm Okay so indeed, after I converted all those files from ES6 format to Node format I was able to include |
With SvelteKit moving us all towards using the ESM format for svelte.config.js (i.e. As a workaround I tried |
You can create a |
@dummdidumm I already have https://github.com/HVSBible/hvsb/blob/main/postcss.config.cjs and am setting |
@jwrunner I have the same issue, have you found a solution or workaround ? |
@Gobi-one I solved my problem by telling svelte-check to validate just js and svelte (not css) by setting |
@jwrunner Thank you for this quick answer. |
+1 @Gobi-one I am having the same issue. I am only getting the "Semicolon or block is expected" error when using |
@lorenzosignoretti |
@Gobi-one Thanks for the reply! I had actually already enabled the |
I have got the same issue
|
Describe the bug
Tailwindcss's latest release contains an experimental feature under the flag
applyComplexClasses
. It, finally, makes@apply
just as powerful as normal element classes. As in, in the past you couldn't write@apply hover:bg-red-200;
because@apply
couldn't handle thehover:
part. Now it finally can. However, now svelte-check will throw an error saying that that is invalid css code.To Reproduce
Sorry, I can't provide a REPL to showcase the simplest example, because this requires setting up tailwindcss in a repo. I used this template and the only change I had to make was to enable the experimental feature in tailwind by adding the following line of code to
tailwind.config.js
:And then editing
src/routes/index.svelte
by adding something like the following in the<style>
element.Expected behavior
What I would like to happen is for svelte-check to somehow understand that I'm using tailwindcss and that then this syntax is valid.
Information about my Svelte project
Severity
It's mostly annoying, because now I have to turn off svelte check in order to continue with my project.
The text was updated successfully, but these errors were encountered: