Published in : 2022-02-13
Hello, I'd like to ask you a question concerning SCSS. When I use @use, I receive the following error:
Invalid CSS after "…": expected expression was "…"
How can I fix it, please?
Join our community and get the chance to solve your code issues & share your opinion with usSign up Now
Mohamed Aboelfotoh Date : 2022-02-13
I experienced the exact same issue. You read about @use on the SASS official web page, follow the instructions, and create the code in the VS code, but when you save the SCSS or SASS file, you receive this weird Compilation Error. You check it all and everything appears to be in order, but it isn't.
In fact te issue stems from the Visual Studio Code extension you're using to convert SCSS or SASS files to CSS files.
Probably you are you using the widly used SASS compiling extension developed by Ritwick Dey. All you need is to replace it with the Live SASS Compiler extension developed by Glenn Marks.