mrcrowl / vscode-easy-less

Easy LESS extension for Visual Studio Code
MIT License
67 stars 23 forks source link

compile errors with calc expression #45

Closed UtillYou closed 5 years ago

UtillYou commented 5 years ago

I have an expression in less:

height: calc(100% - 38px);

output css with:

height: calc(62%);
gibriil commented 5 years ago

I ran into the same issue. You need to escape the code. height: ~"calc(100% - 38px)";

UtillYou commented 5 years ago

I ran into the same issue. You need to escape the code. height: ~"calc(100% - 38px)";

That works. Is this a bug? It works normally when I use other less compiler.

gibriil commented 5 years ago

I honestly can't speak to whether or not this is a bug. I believe it has something to do with the method of compiling. If you use an online compiler like https://lesstester.com/ you have to do the same type of escaping.