tailwindlabs / tailwindcss-intellisense

Intelligent Tailwind CSS tooling for Visual Studio Code
2.82k stars 194 forks source link

scss // comments #928

Closed S-p-Ace closed 6 months ago

S-p-Ace commented 6 months ago

Type: Feature Request

would be nice if comments at the end of a line would be supported in scss files // like this

Extension version: 0.10.5 VS Code version: Code 1.87.2 (863d2581ecda6849923a2118d93a088b0745d9d6, 2024-03-08T15:20:17.278Z) OS version: Windows_NT x64 10.0.22631 Modes:

adamwathan commented 6 months ago

What do you mean by "supported"? Can you give a more specific example of the problem you're having?

S-p-Ace commented 6 months ago

In .scss files, lines containing a comment declared by double slashes // ... at the end will show syntax erros even though it is legal syntax. as a workaround I have to convert the comments to block style /* ... */

When switching the language mode to SCSS the // comments will be parsed as comments (but the tailwind directives will not be recognized)

S-p-Ace commented 6 months ago

maybe I'm using this extension in the wrong place. in 'sass' language mode everything is fine, so I probably don't need tailwindcss specifiacally.

thecrypticace commented 6 months ago

Are you setting the Tailwind CSS language mode explicitly in a Sass/SCSS file? If so, that's not supported right now. The language mode is intended for CSS files/syntax only.

thecrypticace commented 6 months ago

Gonna close this one as the Tailwind CSS language mode is intended for pure CSS and not Sass or SCSS and // comments are not valid in CSS.