nari447
nari447

Reputation: 914

Passing parameters to less file in command line

I am using dotless.compiler.exe in my solution and passing below command in post build event of solution properties.

$(SolutionDir)\packages\dotless.1.1.0\Tools\dotless.Compiler.exe -m "$(ProjectDir)\content*.less" "$(ProjectDir)\content*.css"

My Question is can I pass some parameters to less files in this command ?

Upvotes: 4

Views: 476

Answers (1)

Colin Bacon
Colin Bacon

Reputation: 15619

AFAIK the answer is no. Dotless compiler does not allow you to pass variables in. The only way you can pass variables into a less file is via a querystring parameter when you directly reference to the less file in your page.

Example

<link rel="stylesheet" href="styles.less?bacon=true" />

Upvotes: 4

Related Questions