Questions tagged [dotless]

.less (pronounced dot-less) is a .NET port of the funky Less JavaScript library Lovingly ported by Christopher Owen, Erik van Brakel, Daniel Hoelbling, James Foster and Luke Page

.less (pronounced dot-less) is a .NET port of the funky Less JavaScript library lovingly ported by Christopher Owen, Erik van Brakel, Daniel Hoelbling, James Foster and Luke Page. You can read more about .less at: http://www.dotlesscss.org/

Installation

.less can most easily be installed through its NuGet package:

Install-Package dotless

Links

Differences between Less.js and .less

Though .less is a .NET port of the Less JS library, they do have some differences in terms of the functionalities offered. These differences are described in the official .less GitHub page.

155 questions
27
votes
4 answers

HTTP Error 500.23 after adding dotless to my local website

Hi I'm trying to run dotless on my local .net4 web site My web config looks like this:
Hello-World
  • 9,277
  • 23
  • 88
  • 154
26
votes
7 answers

Visual studio - precompile - dotless

I wonder if there is a way to precompile *.less files(http://www.dotlesscss.org/) with visual studio. The site gives me a dotless.compiler.exe but I am not sure how to hook this up to visual studio. I am looking for a solution for both Webforms and…
Pickels
  • 33,902
  • 26
  • 118
  • 178
25
votes
6 answers

NuGet exited with code -1 — Build failing as a result

I have installed dotless via Package Manager in VS2012 in to an existing mixed C# solution (Class libraries and MVC2 apps), however now when I build it (F5) I get the following two errors: The command…
Canters
  • 411
  • 1
  • 4
  • 6
21
votes
4 answers

Open a file in Visual Studio's CSS Source Editor

I am using Phil Haack's T4CSS T4 template based on .less One bad thing about Phil's solution is that visual studio opens the .less files as plain text files rather than as css files. (Thus no intellisense.) How can I get VS to open a .less file in…
nikmd23
  • 9,095
  • 4
  • 42
  • 57
20
votes
4 answers

Dotless failing to compile ; in Bootstrap 3 less source

I use dotless 1.3.1.0 compiling less-files. This worked fine with bootstrap 2.x, but after switching to bootstrap 3.0.0 (downloaded the source from here: http://getbootstrap.com/getting-started/), I suddenly get this error: Expected ')' but found '…
Stephan Møller
  • 1,247
  • 19
  • 39
15
votes
1 answer

What does DotLess' "web" attribute do exactly?

The dotless documentation is quite limited. I can't find much information at all about the configsection options - especially what the "web" attribute does. Can anyone enlighten me?
cjacques
  • 494
  • 4
  • 14
12
votes
2 answers

Can I use url parameters in LESS css?

Intro: I'm trying out LESS in an asp.net mvc environment. I use dotless for server side processing (and I wouldn't want to use client side processing especially afer publishing the complete project). I have to apply a design where there are…
vinczemarton
  • 7,756
  • 6
  • 54
  • 86
12
votes
7 answers

How can I output errors when using .less programmatically?

I've written an ASP.NET MVC action method that receives a .less file name, processes it via Less.Parse() and outputs the processed css file. This works fine as long as the .less code is valid, but if there is an error, dotLess just…
Adrian Grigore
  • 33,034
  • 36
  • 130
  • 210
11
votes
2 answers

Dotless File Yields 404 Error in IIS

I've been successfully using .less files in my dev Cassini server (with dotless) for a few weeks but when I publish to my local IIS server they yield 404 errors. Attaching my debugger to IIS yields no exceptions. I've restarted my IIS app pool and…
sisdog
  • 2,649
  • 2
  • 29
  • 49
11
votes
2 answers

What is the right syntax for .less variable interpolation?

I've got a .less stylesheet with the following construct: @width:600; .some-style { width:@{width}px; } and this gives the following error: Expected '}' on line x in file '..\styles.less' I need those braces, because I need to distinguish the…
Joshua Frank
  • 13,120
  • 11
  • 46
  • 95
9
votes
1 answer

Is there a CSS object model or CSS querying api for .net?

Is there a library out there that will allow me to write the following kind of code, which parses CSS and returns a queryable object model string input = "p, span { font-family: arial; }"; var cssRules = new Parser().Parse(input); var rule =…
Edward Wilde
  • 25,967
  • 8
  • 55
  • 64
9
votes
2 answers

Dotless - Can't reference less variable in separate file with MVC Bundling

I hope I'm not creating a duplicate topic, but I've been searching for two days and can't find a solution to this. We are starting a new project in MVC4 and we have the less version of bootstrap loaded. The issue I'm running into is when I try to…
Difinity
  • 235
  • 2
  • 12
8
votes
4 answers

DotLess - How to import a LESS file in a parent folder?

I have this folders structure: ~/css/file1.less ~/css/folder/file2.less What I want to do is importing file1.less inside file2.less, so in my file2.less I have this code: @import "../file1.less"; This do not work, and the compiler crash when I…
user1037656
8
votes
4 answers

DotLess IntelliSense In Visual Studio 2010

I've recently found out about the DotLess library and I was so excited about it because CSS has been always annoying for me. I thought this library would be very convenient to use. Unfortunately, once I tried it out, I found out that VS 2010 does…
Kassem
  • 8,116
  • 17
  • 75
  • 116
8
votes
1 answer

Why does LESS convert #fff to white?

If I have: .foo { background-color:#fff; } LESS converts this to: .foo { background-color:white; } Why is this? Do browsers process named colours faster than HEX values? I'm implementing LESS using dotless. Could this be carrying out the…
Curtis
  • 101,612
  • 66
  • 270
  • 352
1
2 3
10 11