An undeclared mixin error when using a semicolon in several parameters.

I am trying to use the mixins.less file from Twitter Bootstrap in my project. All instances of several parameters separated by half-columns show:

Undeclared mix

Function arguments are not closed, ')' is expected.

Undeclared variable

I have installed WebEssentials 2012 v2.9. Is there a way to make this work without using another Less compiler? Or is the compiler in WebEssentials not a problem?

+6
source share
2 answers

Unfortunately, the Web Essentials plugin for Visual Studio did not comply with all LESS CSS standards and fails when semicolons are used as delimiters. At the same time, you will want to convert semicolons to commas, and the downside is that you will not be able to pass a list of arguments.

Web Essentials is constantly being updated, so I won’t be surprised if this is fixed very soon.

+11
source

You cannot use mixins.less yourself. You get errors because mixin.less relies on other files, primarily variables. You, the compiler, should tell you which lines throw the error. If not, try another compiler. I am using Codekit.

You can manually add the missing variables if necessary, although this seems to be a lot of flimsy work. I would suggest either using the entire Bootstrap structure, or just using the specific blending you need and adding to the variables as needed.

0
source

Source: https://habr.com/ru/post/951663/


All Articles